Skip to content

Commit

Permalink
开启sshd
Browse files Browse the repository at this point in the history
  • Loading branch information
pch18 authored Jun 18, 2019
1 parent 7e9bc6c commit 55e619b
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,20 @@ for file in `ls /etc/init.d`
do if [ -x /etc/init.d/${file} ]; then
/etc/init.d/$file restart
fi done

if [ ! -f "/etc/ssh/ssh_host_rsa_key" ];then
ssh-keygen -t rsa -N '' -q -f /etc/ssh/ssh_host_rsa_key
fi
if [ ! -f "/etc/ssh/ssh_host_ecdsa_key" ];then
ssh-keygen -t rsa -N '' -q -f /etc/ssh/ssh_host_ecdsa_key
fi
if [ ! -f "/etc/ssh/ssh_host_ed25519_key" ];then
ssh-keygen -t rsa -N '' -q -f /etc/ssh/ssh_host_ed25519_key
fi
/usr/sbin/sshd

crond

bt default

tail -f /dev/null

0 comments on commit 55e619b

Please sign in to comment.