1
0
mirror of /repos/baseimage-docker.git synced 2026-02-27 17:41:59 +01:00

Do not save SSH host key in baseimage-docker. Instead, generate it automatically during boot.

This commit is contained in:
Hongli Lai (Phusion)
2014-01-31 16:02:01 +01:00
parent d2b28d25a6
commit abf75875a9
3 changed files with 12 additions and 3 deletions

View File

@@ -6,3 +6,5 @@ set -x
apt-get clean
rm -rf /build
rm -rf /tmp/* /var/tmp/*
rm -f /etc/ssh/ssh_host_*

View File

@@ -5,6 +5,7 @@ set -x
## Install init process.
cp /build/my_init /sbin/
mkdir -p /etc/my_init.d
## Install runit.
$minimal_apt_get_install runit
@@ -20,6 +21,7 @@ mkdir /var/run/sshd
mkdir /etc/service/sshd
cp /build/runit/sshd /etc/service/sshd/run
cp /build/config/sshd_config /etc/ssh/sshd_config
cp /build/00_regen_ssh_host_keys.sh /etc/my_init.d/
## Install default SSH key for root and app.
mkdir -p /root/.ssh