Repository navigation
Conversation
…ving OS service
A grid node must continue when the human logs out or the box reboots. A real
node (BIGMAMA) died when a user account was logged off, because the node was
tied to an interactive login session — a direct contradiction of headless-first.
The install registered no session-independent service anywhere.
Adds `continuum service {install,uninstall,status}` (one interface, per-OS impls):
- macOS → LaunchDaemon in /Library/LaunchDaemons (RunAtLoad + KeepAlive, SYSTEM
scope — NOT a LaunchAgent, which dies on logout). plutil-linted.
- Linux → systemd SYSTEM unit (Restart=always, WantedBy=multi-user.target) and
enables the docker engine at boot.
- Windows→ Register-ScheduledTask -AtStartup as SYSTEM (recipe printed; validate
on BIGMAMA).
Honest caveat surfaced by `status` + after install: the node is `docker compose
up -d`, so what must survive logout is the Docker ENGINE. Linux dockerd is
already a system service; Docker Desktop on macOS/Windows is user-session-bound,
so full logout survival there needs a boot-independent engine (colima as a
daemon, or a native headless core). We report that truth, not a fake all-clear.
`status` on a box with no service installed says so plainly ("node dies on
logout. Fix: continuum service install").
Validated WITHOUT activating any live daemon: `--dry-run` generates the artifact
and (macOS) plutil-lints it; bin/tests/service.test.sh drives all three OS
branches by shimming `uname` and asserts each emits a SYSTEM-scope, boot-time,
auto-restart service (13 assertions, green). Live install (sudo) is left to the
operator / a follow-up install.sh integration — auto-installing a boot daemon is
intentionally not silent.
Co-Authored-By: Claude Opus 4.8 <[email protected]>
…Node-independent The first cut had the boot service run `continuum start` = `docker compose up -d`, which brings up node-server (the TypeScript/Node orchestrator) too — dragging Node into the headless node. That contradicts headless-first: the node is the Rust core, independent of Node entirely; node-server/widget-server are the DEPENDENT UI shell (node-server depends_on continuum-core, never the reverse). - Add `continuum start --headless`: brings up ONLY the continuum-core service (no node-server, no widget-server, no Node), waits on the core's health, skips the browser. This is what a grid node / boot service runs. - Repoint the service generators (macOS plist ProgramArguments, Linux unit ExecStart, Windows scheduled task) to `start --headless`. - Engine caveat reworded: the service is core-only; the remaining caveat is just the Docker Desktop engine being session-bound on macOS/Windows. Tests now assert every platform's service runs `start --headless` (Rust core only, no Node). 16/16 green. Co-Authored-By: Claude Opus 4.8 <[email protected]>
…rrides, setting is default Per "we decided to have a config.env setting for this": the headless-vs-ui decision is the ONE config.env setting (CONTINUUM_LAUNCH_MODE), not a bare flag. - `continuum start`: explicit --headless/--ui wins; otherwise resolve via launch_mode (the config.env setting → auto-detect → persist). headless → Rust core only (Node-independent); ui → full stack incl the Node desktop. - `continuum service install [--headless|--ui]`: optional param PINS the service's mode (baked into the plist/unit/task); default (no param) runs plain `continuum start`, so the config.env setting governs at boot. "Take the param, use the setting as default." - Service generators thread the optional mode; status/caveat reworded to say the service honors CONTINUUM_LAUNCH_MODE (headless on a server → no Node). Stacked on feat/launch-mode-setting (needs launch_mode/config_get). Tests: service.test.sh now asserts default pins NO mode (honors the setting) on all three platforms AND that --headless override bakes it in (20 green); launch-mode .test.sh still 18 green. Co-Authored-By: Claude Opus 4.8 <[email protected]>
joelteply
force-pushed
the
feat/node-service-survive-logout
branch
from
June 16, 2026 00:41
587f4c3 to
18eaa1f
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
A grid node must continue when the human logs out or the box reboots. A real node (BIGMAMA, Windows/RTX5090) went down when a user account was logged off — because the node was tied to an interactive login session. That's a direct contradiction of headless-first, and the install registered no session-independent service anywhere.
What
continuum service {install,uninstall,status}— one interface, per-OS implementations (the adapter pattern in shell):/Library/LaunchDaemons(RunAtLoad+KeepAlive, system scope — not a LaunchAgent)Restart=always,WantedBy=multi-user.target) + enablesdockerat bootRegister-ScheduledTask -AtStartupas SYSTEM (recipe printed; validate on BIGMAMA)Honest about the engine caveat
The node is
docker compose up -d, so what must survive logout is the Docker engine. Linuxdockerdis already a system service ✓. Docker Desktop on macOS/Windows is user-session-bound, so full logout-survival there needs a boot-independent engine (colima as a daemon, or a native headless core).statusreports this truth rather than a fake all-clear — and on a box with no service installed it says so plainly: "node dies on logout. Fix: continuum service install."Validated without touching the live system
--dry-rungenerates the artifact and (macOS) plutil-lints it — no sudo, nothing written to/Library/LaunchDaemonsor/etc/systemd.bin/tests/service.test.shdrives all three OS branches by shimminguname, asserting each emits a system-scope, boot-time, auto-restart service (13 assertions, all green).install.shis a deliberate follow-up — installing a boot daemon on someone's machine should not be silent.Closes the node-resilience gap from the BIGMAMA-logoff event; complements the cluster-resilience layer (airc transport #1210, boot-health #1634).
🤖 Generated with Claude Code