ssm-services/init.d/sshd

17 lines
275 B
Plaintext
Raw Normal View History

2013-09-28 23:32:39 +00:00
#!/usr/bin/env watchman
cfg_sshd_cfgdir='/etc/ssh'
2014-07-03 07:05:52 +00:00
service_respawn=true
2015-06-18 09:38:49 +00:00
service_command='/usr/bin/sshd'
2014-07-03 07:05:52 +00:00
service_args="-D -f $cfg_sshd_cfgdir/sshd_config"
2013-09-28 23:32:39 +00:00
sshd_genkeys() {
[[ -e "/etc/ssh/ssh_host_key" ]] || { ssh-keygen -A; }
}
2014-04-04 11:40:00 +00:00
start() {
sshd_genkeys
watchman.start
}