#! /bin/sh # prerm script for ssh # # see: dh_installdeb(1) set -e # summary of how this script can be called: # * `remove' # * `upgrade' # * `failed-upgrade' # * `remove' `in-favour' # * `deconfigure' `in-favour' # `removing' # # for details, see /usr/share/doc/packaging-manual/ case "$1" in remove|deconfigure) case '@DISTRIBUTOR@' in Ubuntu) # Both init script and Upstart job are present; we want to # operate on the Upstart job. if [ -e /etc/init/ssh.conf ]; then stop ssh || true fi ;; *) if [ -x /etc/init.d/ssh ]; then if [ -x /usr/sbin/invoke-rc.d ]; then invoke-rc.d ssh stop else /etc/init.d/ssh stop fi fi ;; esac ;; upgrade|failed-upgrade) ;; *) echo "prerm called with unknown argument \`$1'" >&2 exit 0 ;; esac # dh_installdeb will replace this with shell code automatically # generated by other debhelper scripts. #DEBHELPER# exit 0