Conversation
Signed-off-by: Drew Newberry <[email protected]>
|
The boot hook tests were failing on CI because they used ProcessHandle::spawn which applies Linux sandbox enforcement (seccomp, landlock, privilege dropping) in a pre_exec hook. On CI containers running as root, drop_privileges tried to switch to the non-existent sandbox user, causing EINVAL. Replace run_test_boot_hook and spawn_test_process with a test-specific implementation using plain tokio::process::Command that exercises boot hook logic without sandbox enforcement.
|
Production datapoint from an OpenShell v0.0.25 deployment that just hit the failure mode this PR addresses. After an unexpected host power cycle, the sandbox pods respawned cleanly and reached That is exactly the gap this PR fixes — having the supervisor run On v0.0.25 the workaround is a host-side watchdog: a systemd user timer that curls each forwarded Happy to test this PR on a proxy-only sandbox deployment if the branch is ready for outside verification. |
Summary
Run
/etc/openshell/boot.shas a supervisor-managed startup hook on every sandbox startup before the long-lived child process.Add the shared boot script path constant, cover the hook with startup/failure/regression tests, and document the new sandbox image contract.
Related Issue
None.
Changes
/etc/openshell/boot.shpath inopenshell-policyTesting
mise run pre-commitpassesChecklist