Public: anyone can read this; the crew can change it.

The image the forge ships has no bubblewrap, so every agent run on it is unsandboxed — and only a boot warning says so #405

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

The image now carries bubblewrap and socat, and a run that wasn't sandboxed says so on its own page and on the crew card.

shipped production is serving it deploy 8e3d756

opened this

The image now carries bubblewrap and socat, and a run that wasn't sandboxed says so on its own page and on the crew card.

What changed

  • Dockerfile: bubblewrap and socat are added to the apt line. I did not build the image, so I can't give the size increase or say what sandboxAvailable() answers on it. Whether user namespaces work depends on the platform's seccomp profile, which I couldn't check here. The first boot on the image settles it: the agent sandbox not available here WARN with its reason means refused, no WARN means enforced.
  • Run record: two new columns on run, sandbox_enforced (null for old runs) and sandbox_note (migration 39). The runner writes them when the run starts, from the policy it actually hands Claude Code. The policy itself is unchanged.
  • Run page: a new src/web/studio/sandbox.ts renders "Unsandboxed: the shell ran unrestricted (reason)" or "Sandboxed". The reason is escaped. It shows on both the studio and the ?mode=dev run pages. Runs from before this change show nothing, since their state is unknown.
  • Crew card: CrewHandle now carries sandbox, and Settings → Crew shows an "Unsandboxed" note with the reason when it isn't enforced.
  • README: a Sandbox paragraph in The crew section says which of the two a deployment is in and how to tell.
  • Tests: test/crew-sandbox.test.ts now checks that the run keeps enforced for both values and that a later progress note doesn't erase it. It also checks that the unsandboxed line escapes the reason, and that an unrecorded run says nothing.

Tests

  • crew-sandbox, crew, runs-lease and board pass.
  • I did not get a full bun test result (the run didn't finish here).
  • tsc isn't usable here (missing bun types), so nothing was type-checked.

Not done

  • No chart or release workflow changes.
  • No weakening of the policy.
  • The home and board cards don't show the sandbox state; only the run page and the crew card do.

To try it, assign an issue to an agent on a host without bubblewrap. The run page shows "Unsandboxed (bwrap is not installed)" and Settings → Crew shows the same note.

🤖 Generated with Claude Code

Closes #298

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs