carlos / platform Public

gvisor demos: stop with runsc kill and KillSignal=SIGCONT (spec rev 5.5)

Root runner 20261108T222447-ac9140: runsc wait races the attached
run's state cleanup. Stop sends TERM via runsc kill, and systemd's
follow-up signal to runsc is SIGCONT so it waits for runsc to exit.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
claude agent, operated by paul@keymail.dev pushed by paul@keymail.dev f95e6a136314f978cfe1e1439362c06292773087 parent 5a9142f
1 file changed, +7 −4
  • docs/superpowers/specs/2026-11-08-gvisor-demos-design.md +7 −4

CI failed — run details

diff --git a/docs/superpowers/specs/2026-11-08-gvisor-demos-design.md b/docs/superpowers/specs/2026-11-08-gvisor-demos-design.md
index 478be7e73..c792bb660 100644
--- a/docs/superpowers/specs/2026-11-08-gvisor-demos-design.md
+++ b/docs/superpowers/specs/2026-11-08-gvisor-demos-design.md
@@ -1,4 +1,4 @@
-# gVisor sandbox for anonymous demos: design (2026-11-08, rev 5.4)
+# gVisor sandbox for anonymous demos: design (2026-11-08, rev 5.5)
Discussion: amadan carlos/platform #527. Spike: `~/.cache/gvisor-spike/REPORT.md`
and `astra-integration.md` (2026-11-07, runsc release-20261102.0, systrap, t4g).
@@ -293,9 +293,12 @@ fit.
**Rev 5.4 (build rulings, root runner `20261108T221438-3cee35`):** `runsc run` does not
forward SIGTERM to the guest (exit record `code=killed status=TERM`, no guest receipt).
-Graceful stop is explicit: `ExecStop=<runsc> --root=/run/carlos-runsc kill <id> TERM`
-then `ExecStop=<runsc> --root=/run/carlos-runsc wait <id>`, bounded by
-`TimeoutStopSec`, after which systemd kills the whole cgroup. The asserted runsc run
+Graceful stop is explicit (rev 5.5, root runner `20261108T222447-ac9140`: a separate
+`runsc wait` races the attached run's own state cleanup): `ExecStop=-<runsc>
+--root=/run/carlos-runsc kill <id> TERM`, no wait command, and `KillSignal=SIGCONT`, so
+the signal systemd sends the main process after ExecStop is a no-op and systemd waits
+for `runsc run` to exit when the guest does. `KillMode=mixed` and `TimeoutStopSec`
+still SIGKILL the whole cgroup if the guest does not exit. The asserted runsc run
argv gains `--overlay2=none` (measured: both `none` and `root:memory` pass every
check; `none` has no writable root layer). The paragraph below is superseded where
it says runsc forwards TERM.