mirror of
/repos/baseimage-docker.git
synced 2025-12-30 08:01:31 +01:00
Fix bugs, added README
This commit is contained in:
parent
9661f84da9
commit
aee8c8368f
15
README.md
Normal file
15
README.md
Normal file
@ -0,0 +1,15 @@
|
||||
|
||||
# Use phusion/baseimage as base image. To make your builds reproducible, make
|
||||
# sure you lock down to a specific version, not to `latest`!
|
||||
FROM phusion/baseimage:<VERSION>
|
||||
|
||||
# Remove authentication rights for insecure_key.
|
||||
RUN rm -f /root/.ssh/authorized_keys /home/*/.ssh/authorized_keys
|
||||
|
||||
# Use baseimage-docker's init process.
|
||||
CMD ["/sbin/my_init"]
|
||||
|
||||
# ...put other build instructions here...
|
||||
|
||||
# Clean up APT when done.
|
||||
RUN apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
|
||||
@ -4,5 +4,5 @@ source /build/buildconfig
|
||||
set -x
|
||||
|
||||
apt-get clean
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
rm -rf /build
|
||||
rm -rf /tmp/* /var/tmp/*
|
||||
|
||||
@ -22,9 +22,7 @@ cp /build/runit/sshd /etc/service/sshd/run
|
||||
cp /build/config/sshd_config /etc/ssh/sshd_config
|
||||
|
||||
## Install default SSH key for root and app.
|
||||
mkdir -p /root/.ssh /home/app/.ssh
|
||||
chmod 700 /root/.ssh /home/app/.ssh
|
||||
mkdir -p /root/.ssh
|
||||
chmod 700 /root/.ssh
|
||||
chown root:root /root/.ssh
|
||||
chown app:app /home/app/.ssh
|
||||
cat /build/insecure_key.pub > /root/.ssh/authorized_keys
|
||||
cat /build/insecure_key.pub > /home/app/.ssh/authorized_keys
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user