Public: anyone can read this; the crew can change it.
Crew runs as cluster Jobs: crew.placement process | job #1908
crew.placement is now a capacity setting (process, the default, or job). With job, the builder's Claude Code runs as a cluster Job through the same runJob client as checks.
stopped parked by the crew
2 earlier comments
crew.placement: job now runs the builder's claude as a cluster Job. The clone goes over the forge, the log is streamed, and a Job that vanishes is queued again once (#1426).
The failed check came from one missing line. test/crew-job.test.ts was in neither list in scripts/gate.ts, so I added it to GATE next to the other crew tests.
bun scripts/gate.ts now passes with no output. test/crew-job.test.ts passes (6 tests). I did not run the type check, and the forge's full check runs on this push.
I changed no code and no test.
I merged main into the branch and pushed it, which should clear the "does not merge into main" failure. The forge's check on the new push hasn't reported yet.
src/cluster/jobs.ts conflicted. main now makes runJob throw JobVanished when a Job is gone, and my branch returned vanished: true instead. I took main's way and dropped my vanished field from the result. The crew launcher in src/crew/job_launch.ts now catches JobVanished and sets the same "vanished" flag the runner already uses to queue the run again once. I changed the "Job is gone" test in test/crew-job.test.ts to expect the JobVanished throw.
The type check and these tests pass locally:
test/crew-job.test.tstest/checks-job-vanish.test.tstest/gate.test.tstest/cluster-jobs.test.ts
bun scripts/gate.ts also passes.
One change in behaviour: a Job that vanishes mid-run no longer hands back the partial log lines it had collected.
Parked by the crew: the check stayed red through 2 automatic tries
crew.placementis now a capacity setting (process, the default, orjob). Withjob, the builder's Claude Code runs as a cluster Job through the samerunJobclient as checks. The new crew-job tests pass against a stand-in kube client, and the neighbouring crew, capacity, checks, web, board and sentinel suites ran with one failure.tscis clean. That failure, intest/capacity.test.ts, also fails on the base branch: it asserts noFORGE_CHECK_SHARDSis set, and this sandbox sets it to 4. I have not run the real-cluster path.What changed
src/core/capacity.tshas the new key, reachable from Settings → Capacity, the API and MCP.src/crew/job_placement.tsreads the image, node selector and tolerations fromFORGE_CREW_IMAGE,FORGE_CREW_NODE_SELECTORandFORGE_CREW_TOLERATIONS. Without a usable image the run stays on the forge.src/crew/claude.tsgained a launcher seam, sorunClaudedrives a child process or a Job unchanged.src/cluster/jobs.tsfollows the pod log and hands each line toonLineexactly once. Each line goes into the run log as the transcript, andplacementandnodeare recorded on the run. A Job that disappears (404) reportsvanished. The run is interrupted and queued again once, then fails.docs/APPS.mdhas a "Crew placement" paragraph.Left out or to check
charts/app/templates/lane.yamlis not in this repository, so I could not touch the NetworkPolicy. The pod carriesforge-lane=agent, and someone needs to match that label in the chart.To try it
FORGE_CREW_IMAGEto an image with git and Claude Code.crew.placementtojobon/settings/capacity.bun test test/crew-job.test.tscovers the success path, the Job's shape, and the vanish-once-then-fail path.🤖 Generated with Claude Code
Closes #1426