generate ssh keys

Signed-off-by: Nico Schottelius <nico@wurzel.schottelius.org>
This commit is contained in:
Nico Schottelius 2015-06-16 11:14:50 +02:00
commit cc144d9e8f
5 changed files with 38 additions and 53 deletions

View file

@ -9,6 +9,7 @@ dir=$1
mkdir -p "$dir/etc/ssh"
mkdir -p "$dir/root/.ssh"
mkdir -p "$dir/lib"
cat << eof > "$dir/etc/ssh/sshd_config"
# cdist generated - do not modify
@ -25,6 +26,20 @@ root:x:0:root
nobody:x:99:
eof
# libpam not found
# /etc/ssl/openssl.cnf
# /etc/gai.conf
# no nscd socket
# /etc/nsswitch.conf
# libnss_compat.so.2
# libnss_files.so.2
# Fixes the user problem
cp /lib/libnss* "$dir/lib"
# Required by sshd
mkdir -p "$dir/var/empty"
#cat << eof > "$dir/etc/shadow"
#root:x:0:0:root:/root:/bin/bash
#nobody:x:1::::::