#! /bin/sh # postrm script for pure-ftpd set -e # summary of how this script can be called: # * `remove' # * `purge' # * `upgrade' # * `failed-upgrade' # * `abort-install' # * `abort-install' # * `abort-upgrade' # * `disappear' overwrit>r> # for details, see /usr/share/doc/packaging-manual/ case "$1" in purge) [ -x /usr/sbin/update-inetd ] && /usr/sbin/update-inetd --remove ftp # completely remove configuration directory rm -rf /etc/pure-ftpd # remove log files and runtime directory rm -rf /var/log/pure-ftpd /var/run/pure-ftpd ;; remove) if which update-inetd >/dev/null 2>&1; then update-inetd --disable ftp fi ;; abort-install) if which update-inetd >/dev/null 2>&1; then test $2 || update-inetd --remove ftp fi ;; upgrade|failed-upgrade|abort-upgrade|disappear) ;; *) echo "postrm called with unknown argument \`$1'" >&2 exit 0 ;; esac # dh_installdeb will replace this with shell code automatically # generated by other debhelper scripts. # Automatically added by dh_installdebconf if [ "$1" = purge ] && [ -e /usr/share/debconf/confmodule ]; then . /usr/share/debconf/confmodule db_purge fi # End automatically added section