aboutsummaryrefslogtreecommitdiffstats
path: root/debian/postrm
diff options
context:
space:
mode:
authorMikhail Gusarov <dottedmag@debian.org>2015-03-07 10:23:13 +0000
committerAndrew Lewis <nerf@judo.za.org>2015-03-17 18:58:34 +0200
commite10ddbdaefe0c74875648bf182e000d0b5e42a82 (patch)
treecdf71839278ddcbc8c75454e11d6d39d2378aff4 /debian/postrm
parentaf765c345234e920a4c45ba24af156a029304ab9 (diff)
downloadrspamd-e10ddbdaefe0c74875648bf182e000d0b5e42a82.tar.gz
rspamd-e10ddbdaefe0c74875648bf182e000d0b5e42a82.zip
Work around Debian mishandling of systemd socket-activated units
If there is a backward compatibility sysvinit script, then even socket-activated services are started automatically after install/upgrade.
Diffstat (limited to 'debian/postrm')
-rw-r--r--debian/postrm8
1 files changed, 8 insertions, 0 deletions
diff --git a/debian/postrm b/debian/postrm
index 10a84805e..0ab952d46 100644
--- a/debian/postrm
+++ b/debian/postrm
@@ -1,6 +1,14 @@
#!/bin/sh
set -e
+if [ "$1" = "purge" ]; then
+ update-rc.d rspamd remove >/dev/null
+fi
+
+if [ -d /run/systemd/system ]; then
+ systemctl --system daemon-reload >/dev/null || true
+fi
+
#DEBHELPER#
case "$1" in