mirror of
https://git.proxmox.com/git/pmg-api
synced 2026-01-24 19:20:17 +00:00
45 lines
1.1 KiB
Bash
45 lines
1.1 KiB
Bash
#!/bin/sh
|
|
|
|
set -e
|
|
|
|
|
|
case "$1" in
|
|
triggered)
|
|
|
|
test -e /proxmox_install_mode && exit 0;
|
|
|
|
# Note: reload-or-try-restart fails if service is not active
|
|
systemctl --quiet is-active pmgdaemon.service && deb-systemd-invoke reload-or-try-restart pmgdaemon.service
|
|
systemctl --quiet is-active pmgproxy.service && deb-systemd-invoke reload-or-try-restart pmgproxy.service
|
|
systemctl --quiet is-active pmg-smtp-filter.service && deb-systemd-invoke reload-or-try-restart pmg-smtp-filter.service
|
|
systemctl --quiet is-active pmgpolicy.service && deb-systemd-invoke reload-or-try-restart pmgpolicy.service
|
|
|
|
exit 0
|
|
;;
|
|
|
|
configure)
|
|
|
|
test -e /proxmox_install_mode || pmgdb init
|
|
test -e /proxmox_install_mode || pmgdb update >/dev/null 2>&1 &
|
|
test -e /proxmox_install_mode || pmgconfig init
|
|
|
|
update-mime-database /usr/share/mime
|
|
|
|
;;
|
|
|
|
abort-upgrade|abort-remove|abort-deconfigure)
|
|
;;
|
|
|
|
*)
|
|
echo "postinst called with unknown argument \`$1'" >&2
|
|
exit 1
|
|
;;
|
|
esac
|
|
|
|
# dh_installdeb will replace this with shell code automatically
|
|
# generated by other debhelper scripts.
|
|
|
|
#DEBHELPER#
|
|
|
|
exit 0
|