fix(systemd): set Restart=always and PUBSCRIPT_WEB_DIST in user service and force-restart on .deb install
CI / build (push) Waiting to run
CI / build (push) Waiting to run
This commit is contained in:
@@ -148,9 +148,10 @@ fi
|
||||
if command -v gtk-update-icon-cache >/dev/null 2>&1; then
|
||||
gtk-update-icon-cache -q -t -f /usr/share/icons/hicolor || true
|
||||
fi
|
||||
# Stop any stale background server from a previous package build so the next
|
||||
# launch or systemd restart serves the updated /opt/pubscript bundle cleanly.
|
||||
pkill -f "/opt/pubscript/server/dist/server.mjs" >/dev/null 2>&1 || true
|
||||
# Stop any stale background server from a previous package build so systemd
|
||||
# (Restart=on-failure / Restart=always) or the next desktop launch starts the
|
||||
# freshly installed /opt/pubscript server and asset bundle.
|
||||
pkill -9 -f "/opt/pubscript/server/dist/server.mjs" >/dev/null 2>&1 || true
|
||||
exit 0
|
||||
EOF
|
||||
chmod 0755 "$STAGE_DIR/DEBIAN/postinst"
|
||||
|
||||
Reference in New Issue
Block a user