reconfigure openssh server in noninteractive mode

dpkg-reconfigure fails to run without a tty, pty, or some such, so tell
it to just run.

fixes #495

Signed-off-by: Justin Charette <charetjc@gmail.com>
This commit is contained in:
Justin Charette 2015-11-16 20:41:40 -05:00
parent 369126bdd6
commit 035ffd1f1e

View File

@ -320,7 +320,7 @@ fi
if [[ ! -e ${GITLAB_DATA_DIR}/ssh/ssh_host_rsa_key ]]; then
# create ssh host keys and move them to the data store.
dpkg-reconfigure openssh-server
dpkg-reconfigure -f noninteractive openssh-server
mkdir -p ${GITLAB_DATA_DIR}/ssh/
mv /etc/ssh/ssh_host_*_key /etc/ssh/ssh_host_*_key.pub ${GITLAB_DATA_DIR}/ssh/
fi