From b3b47b6b602c23e3426d3c23c0d060cc86d9194d Mon Sep 17 00:00:00 2001 From: s3lph Date: Sun, 1 Dec 2024 23:44:26 +0100 Subject: [PATCH] fix: debian postinst/prerm scripts --- package/debian/matemat/DEBIAN/postinst | 3 ++- package/debian/matemat/DEBIAN/prerm | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/package/debian/matemat/DEBIAN/postinst b/package/debian/matemat/DEBIAN/postinst index f2b9ccc..44e19fe 100755 --- a/package/debian/matemat/DEBIAN/postinst +++ b/package/debian/matemat/DEBIAN/postinst @@ -16,6 +16,7 @@ if [[ "$1" == "configure" ]]; then chmod 0750 /var/lib/matemat ln -sf /var/lib/matemat/upload /usr/lib/matemat/static/upload - systemctl daemon-reload || true + deb-systemd-helper enable matemat.service + deb-systemd-invoke restart matemat.service fi diff --git a/package/debian/matemat/DEBIAN/prerm b/package/debian/matemat/DEBIAN/prerm index 85ae20e..606a9f0 100755 --- a/package/debian/matemat/DEBIAN/prerm +++ b/package/debian/matemat/DEBIAN/prerm @@ -4,6 +4,6 @@ set -e if [[ "$1" == "remove" ]]; then - userdel matemat + deb-systemd-invoke stop matemat.service fi