ssm-services/services/sshd

15 lines
248 B
Plaintext
Raw Normal View History

#!/usr/bin/env ssm
2013-09-28 23:32:39 +00:00
cfg_sshd_cfgdir='/etc/ssh'
service_respawn=always
service_command=( /usr/bin/sshd -D -f "$cfg_sshd_cfgdir/sshd_config" )
2013-09-28 23:32:39 +00:00
depends_ready=( znet )
2015-09-04 13:47:37 +00:00
pre_start() {
if ! [[ -e "/etc/ssh/ssh_host_key" ]]; then
ssh-keygen -A
fi
2013-09-28 23:32:39 +00:00
}