diff --git a/resources/install-scripts/post-install.in b/resources/install-scripts/post-install.in index edb76cb9..69854670 100755 --- a/resources/install-scripts/post-install.in +++ b/resources/install-scripts/post-install.in @@ -6,6 +6,6 @@ echo "Installing AppImageLauncher as interpreter for AppImages" # as there's no _real_ package that we could use as a dependency to take care of the kernel module, # we need to make sure that the kernel module is loaded manually -modprobe -v binfmt_misc +modprobe -v binfmt_misc || : -(set -x; systemctl restart systemd-binfmt) +systemctl try-restart systemd-binfmt.service || echo "ERROR: failed to execute 'systemctl try-restart systemd-binfmt.service', apply binfmt integration manually" >&2 diff --git a/resources/install-scripts/post-uninstall.in b/resources/install-scripts/post-uninstall.in index d27e46ea..076105a3 100755 --- a/resources/install-scripts/post-uninstall.in +++ b/resources/install-scripts/post-uninstall.in @@ -3,7 +3,7 @@ set -eo pipefail echo "Removing AppImageLauncher as interpreter for AppImages" -(set -x; systemctl restart systemd-binfmt) +systemctl try-restart systemd-binfmt.service || echo "ERROR: failed to execute 'systemctl try-restart systemd-binfmt.service', apply/remove binfmt integration manually" >&2 update_notifier="/usr/share/update-notifier/notify-reboot-required" if [ -x "$update_notifier" ]; then