1
0
Fork 0

Add file /etc/ssh/sshd_config

This commit is contained in:
Braiden Vasco 2017-10-30 14:08:19 +00:00
parent cfb4c0b763
commit 91e06c12cc
2 changed files with 28 additions and 0 deletions

View File

@ -162,6 +162,8 @@ on_chroot << EOF
apt-get install -y ssh
EOF
apply_file 644 '/etc/ssh/sshd_config'
rm -fv "$ROOTFS_DIR/etc/ssh/ssh_host_key"
rm -fv "$ROOTFS_DIR/etc/ssh/ssh_host_key.pub"

26
files/etc/ssh/sshd_config Normal file
View File

@ -0,0 +1,26 @@
# See the sshd_config(5) manpage for details
Protocol 2
Port 22
AddressFamily inet
HostKey /etc/ssh/ssh_host_key
HostKey /etc/ssh/ssh_host_rsa_key
HostKey /etc/ssh/ssh_host_dsa_key
HostKey /etc/ssh/ssh_host_ecdsa_key
HostKey /etc/ssh/ssh_host_ed25519_key
# Change to "no" after ssh-copy-id
PasswordAuthentication yes
PermitRootLogin no
ChallengeResponseAuthentication no
LoginGraceTime 120
TCPKeepAlive yes
PrintMotd no
PrintLastLog yes
Subsystem sftp /usr/lib/openssh/sftp-server