scripts/webui-service.sh render|install|uninstall|status and the packages/webui/systemd/mosaic-webui.service.in template, on the bus-service.sh pattern. install writes the unit to a temp file, renames it and runs only `systemctl --user daemon-reload`. There is no start, stop, enable or restart verb: the Console reads the bus through the human transport, so Jason starts it from his own shell (lead decisions 62 and 94). Serve's flags pass through, including row 74's preview set, each held to a character set the unit can carry. The unit sets no MOSAIC_*, CLAUDE*, CODEX* or PI_* variable and does not restart on serve's exit 2. Tests in packages/webui/tests/service.test.mjs; TOOLS.md entry. Author: Rocko. Candidate manifest 7dc571dbe87a484f465c82e1965e499c57d9af047bfe702faa3fe041138dd154 (agents/rocko/work/queue-75/, base43d2328f, no drift on the manifest paths to8b351c3d). Approved by Filbert, comment 27430 on #1569, with five non-blocking notes placed in row 77. Sage gate rerun on a worktree of8b351c3dwith the patch: manifest OK; webui 50/50; test-auth 15, conductor 17, config 24, discord 66, extension-package 18, foundation 44, queue 27, release 14, task 98, all passed, 0 failed. Co-Authored-By: Claude Opus 5.5 <[email protected]>
36 lines
1.4 KiB
Plaintext
36 lines
1.4 KiB
Plaintext
# Mosaic Console: `node packages/webui/src/cli.mjs serve`, one instance.
|
|
# Rendered by scripts/webui-service.sh from packages/webui/systemd/; @REPO@,
|
|
# @PATH@, @NODE@ and the serve flags below are filled in at install time.
|
|
# Edit the template and reinstall; do not edit the installed copy.
|
|
#
|
|
# The Console reads the bus through the human transport, so whoever starts
|
|
# this unit holds the human's capability. Jason starts it from his own
|
|
# shell (`systemctl --user enable --now mosaic-webui`); an agent starting
|
|
# it works around the human proof (lead decisions 62 and 94). The unit sets
|
|
# no MOSAIC_*, CLAUDE*, CODEX* or PI_* variable.
|
|
[Unit]
|
|
Description=Mosaic Console
|
|
Documentation=file://@REPO@/packages/webui/README.md
|
|
StartLimitIntervalSec=600
|
|
StartLimitBurst=5
|
|
|
|
[Service]
|
|
Type=simple
|
|
WorkingDirectory=@REPO@
|
|
Environment=PATH=@PATH@
|
|
# The server binds 127.0.0.1 only. Usage, config and listen refusals
|
|
# (a port already in use included) exit 2 and are not retried; fix the
|
|
# flags or free the port, then start it again.
|
|
ExecStart=@NODE@ @REPO@/packages/webui/src/cli.mjs serve @FLAGS@
|
|
Restart=on-failure
|
|
RestartSec=15
|
|
RestartPreventExitStatus=2
|
|
# `systemctl --user stop` sends SIGTERM; the server stops accepting and
|
|
# closes. Open connections that outlast TimeoutStopSec are killed.
|
|
KillSignal=SIGTERM
|
|
TimeoutStopSec=30
|
|
NoNewPrivileges=yes
|
|
|
|
[Install]
|
|
WantedBy=default.target
|