X-Git-Url: http://ftp.carnet.hr/carnet-debian/scm?a=blobdiff_plain;f=debian%2Fpostrm;h=961ffe72aad02326dca119ed26fd22e776c63d64;hb=d9a6ac164d82f634d18097e23a0d1fda49104d05;hp=434672cf19c94f8196562d44e2a0b6b2cc43a055;hpb=5f60b25a07dea5c8672a7abbcbb8dc0e1e521f19;p=monit-cn.git diff --git a/debian/postrm b/debian/postrm index 434672c..961ffe7 100755 --- a/debian/postrm +++ b/debian/postrm @@ -1,5 +1,5 @@ #!/bin/sh -# postrm script for monit-cn +# postrm script for bind9-cn # # see: dh_installdeb(1) @@ -27,24 +27,11 @@ case "$1" in ;; esac -## import CN-functions -#. /usr/share/carnet-tools/functions.sh -# -## remove us from inittab -#echo "CN: Removing monit service from /etc/inittab" -#cp-update -r monit-cn /etc/inittab -# -## remove us from systemv monit script -#echo "CN: Removing monit workaround from /etc/init.d/monit" -#cp-update -r monit-cn /etc/init.d/monit -#chmod +x /etc/init.d/monit -# -## kill monit -#echo "CN: Stopping monit service" -#pkill -9 -f /usr/bin/monit || true -# -## reload init -#telinit q +# Brisemo /etc/monit, ali samo ako paket MONIT nije vise instaliran + +if [ $(dpkg-query -W -f='${Status}' monit 2> /dev/null | grep -c "ok installed" || true) -ne "0" ]; then + rm -fr /etc/monit +fi # dh_installdeb will replace this with shell code automatically # generated by other debhelper scripts.