1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
|
#!/bin/sh
set -e
# Remove the cache file so that the directory can be deleted.
#
if [ "$1" = "remove" -o "$1" = "purge" ]; then
rm -f /var/cache/ddclient/ddclient.cache
fi
#DEBHELPER#
# Usually the above DEBHELPER magic comment is replaced with some code
# that stops the service. In our case, the --no-start option was used
# to make it possible to conditionally enable the service. The
# --no-start option also disables stopping the service on remove, so
# it has to be manually stopped here.
#### Begin part generated by dh_installsystemd/13.11.1
if [ -z "${DPKG_ROOT:-}" ] && [ "$1" = remove ] && [ -d /run/systemd/system ] ; then
deb-systemd-invoke stop 'ddclient.service' >/dev/null || true
fi
#### End part generated by dh_installsystemd/13.11.1
#### Begin part generated by dh_installinit/13.11.1
if [ -z "${DPKG_ROOT:-}" ] && [ "$1" = remove ] && [ -x "/etc/init.d/ddclient" ] ; then
invoke-rc.d --skip-systemd-native ddclient stop || exit 1
fi
#### End part generated by dh_installinit/13.11.1
exit 0
|