Use deb-systemd-invoke instead of systemctl in zoneminder.postinst
This commit is contained in:
parent
bf945cf6f3
commit
4bf1be59cd
|
@ -18,7 +18,7 @@ if [ "$1" = "configure" ]; then
|
||||||
echo 'grant lock tables, alter,select,insert,update,delete on zm.* to 'zmuser'@localhost identified by "zmpass";' | mysql --defaults-file=/etc/mysql/debian.cnf mysql
|
echo 'grant lock tables, alter,select,insert,update,delete on zm.* to 'zmuser'@localhost identified by "zmpass";' | mysql --defaults-file=/etc/mysql/debian.cnf mysql
|
||||||
fi
|
fi
|
||||||
|
|
||||||
systemctl stop zoneminder.service || true
|
deb-systemd-invoke stop zoneminder.service || true
|
||||||
zmupdate.pl --nointeractive
|
zmupdate.pl --nointeractive
|
||||||
|
|
||||||
else
|
else
|
||||||
|
@ -34,11 +34,7 @@ if [ "$1" = "configure" ]; then
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
# Ensure zoneminder is stopped...
|
# Ensure zoneminder is stopped...
|
||||||
if [ -f "/lib/systemd/system/zoneminder.service" ]; then
|
deb-systemd-invoke stop zoneminder.service || exit $?
|
||||||
if systemctl status zoneminder.service ; then
|
|
||||||
systemctl stop zoneminder.service || exit $?
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "$1" = "configure" ]; then
|
if [ "$1" = "configure" ]; then
|
||||||
if [ -z "$2" ]; then
|
if [ -z "$2" ]; then
|
||||||
|
|
Loading…
Reference in New Issue