From b01a179cef6b9ddb82acf8a154d184c124a0ecdb Mon Sep 17 00:00:00 2001 From: Colin Watson Date: Thu, 1 Nov 2012 11:20:08 +0000 Subject: Add an Upstart job (not currently used by default in Debian). --- debian/openssh-server.ssh.upstart | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 debian/openssh-server.ssh.upstart (limited to 'debian/openssh-server.ssh.upstart') diff --git a/debian/openssh-server.ssh.upstart b/debian/openssh-server.ssh.upstart new file mode 100644 index 000000000..d8342b9c1 --- /dev/null +++ b/debian/openssh-server.ssh.upstart @@ -0,0 +1,27 @@ +# ssh - OpenBSD Secure Shell server +# +# The OpenSSH server provides secure shell access to the system. + +description "OpenSSH server" + +start on filesystem or runlevel [2345] +stop on runlevel [!2345] + +respawn +respawn limit 10 5 +umask 022 + +# 'sshd -D' leaks stderr and confuses things in conjunction with 'console log' +console none + +pre-start script + test -x /usr/sbin/sshd || { stop; exit 0; } + test -e /etc/ssh/sshd_not_to_be_run && { stop; exit 0; } + test -c /dev/null || { stop; exit 0; } + + mkdir -p -m0755 /var/run/sshd +end script + +# if you used to set SSHD_OPTS in /etc/default/ssh, you can change the +# 'exec' line here instead +exec /usr/sbin/sshd -D -- cgit v1.2.3