Przeglądaj źródła

Merge pull request #6390 from qzhuyan/fix/william/systemd-restart-on-failure

build(deb): fix postrm for checking systemd
William Yang 4 lat temu
rodzic
commit
3fdc075b24
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      deploy/packages/deb/debian/postrm

+ 1 - 1
deploy/packages/deb/debian/postrm

@@ -56,7 +56,7 @@ case "$1" in
                 rm -r /usr/lib/emqx
                 rm -r /usr/lib/emqx
         fi
         fi
 
 
-        if pidof systemd; then
+        if systemctl status --no-pager; then
           systemctl disable emqx;
           systemctl disable emqx;
           rm -f /etc/systemd/emqx.service
           rm -f /etc/systemd/emqx.service
         fi
         fi