GeezerVison is showing github.com — fleet: fleet-command dispatch container cannot run nix develop out of the box (experimental features, nixbld group, homeless-shelter purity) · Issue #13159 · developing-today/code
fleet: fleet-command dispatch container cannot run nix develop out of the box (experimental features, nixbld group, homeless-shelter purity) #13159DescriptionFound 2026-11-23 (Lane ON, archer) while verifying #3810's test oracle through the dispatch-first route the fleet runbook now prescribes (pkgs/fleet/doc/agents/remote-build-and-test.md, PR #13128). The standard form — dispatch cd pkgs/id && nix develop --command cargo test … against developing-today/code at 3a941eff430e — cannot run in the fleet-build:full container today. Three dispatches on GitHub-hosted surfaces failed in sequence, each on a container-environment gap, before any test code ran:
- Run 45142821380 (fleet-forks surface):
error: experimental Nix feature 'nix-command' is disabled; add '--extra-experimental-features nix-command' to enable it
- Run 45143247862 (with the experimental-features flag added):
error: the group 'nixbld' specified in 'build-users-group' does not exist
- Run 45144080446 (with
--option build-users-group "" added): error: home directory "/homeless-shelter" exists; please remove it to assure purity of builds without sandboxing
The same test suite run locally on the laptop's NixOS (nix develop --command cargo test -p id --lib hosted_export) passed 9/9, so the code and the flake are fine — only the container's nix setup is missing the pieces every dispatched nix job will need.
Ask
Make the boring form work end-to-end in the dispatch container (image and/or the fleet-command workflow's setup step):
- enable
nix-command + flakes in the image's nix configuration;
- provide the
nixbld group/users the default build-users-group expects (the org-run venue got the equivalent fix in PR fix(ci): configure single-user nix in org-run legs #12908), or set a working default;
- give builds a HOME that passes nix's unsandboxed purity check.
Also observed on the fourth dispatch of the same job: placement auto-selected the fleet-org-blacksmith surface (handle fp_8e8fee9d289b543b1129d998b5fa1a0c) although no --runner blacksmith was requested and the job is a routine test run. No run had materialized when checked minutes later, so no minutes were confirmed burned — but auto-placement onto metered Blacksmith runners for ordinary jobs deserves a look under the same "dispatch must be boring" heading (Drew's rule: Blacksmith only when a job truly needs it).
Acceptance
fleet queue dispatch --repo developing-today/code --ref <main sha> --command 'cd pkgs/id && nix develop --command cargo test -p id --lib hosted_export' --dispatch --json succeeds on a GitHub-hosted surface with no extra nix flags in the command.
- The runbook's dispatch examples work verbatim.
{
"direct_parent": null,
"links": [],
"lineage": {
"design": null,
"roadmap_item": null,
"priority": null
},
"pm_meta": 1,
"provenance": {
"queue_id": null,
"scheduled_start": null,
"picked_up_at": null,
"work_started_at": null,
"created_at": "2026-11-23T09:26:43Z",
"session_id": null,
"lane": null,
"host": "htch-runtime",
"worktree": null,
"model": null,
"lane_start_issues": [],
"workspace_ref": null,
"auth_subject": "archer",
"stamped_by": "fleet 0.1.0 (native)"
}
}
Activitydeveloping-today commented on Nov 23, 2026 dezren39 commented on Nov 23, 2026 Lane QB (archer) claiming this issue.
Premise verified from the issue's own evidence: three dispatched runs on GitHub-hosted surfaces each failed on a container nix gap before any test code ran (experimental features disabled; nixbld group missing; /homeless-shelter purity check), while the same suite passed 9/9 on the laptop's NixOS — the code and flake are fine, only the dispatch container's nix setup is missing pieces.
Scope I am taking: the container/workflow fix so the boring dispatch form works end-to-end —
nix-command + flakes enabled in the image's nix configuration;
- the
nixbld group/users provided (or a working build-users-group default), matching the equivalent org-run fix in PR fix(ci): configure single-user nix in org-run legs #12908;
- a HOME that passes nix's unsandboxed purity check.
Out of scope for this slice: the Blacksmith auto-placement observation (fourth dispatch auto-selected fleet-org-blacksmith without a --runner request). That belongs with the placement improvement program — pointer to #13146 — and is not part of this issue's acceptance criteria. dezren39 commented on Nov 23, 2026 Lane QB — HOLD record on #13159 (execution stopped on a platform flag; awaiting Drew's item-specific approval).
Premise: verified TRUE from the issue's own evidence (three dispatched runs failing on the three container nix gaps; same suite green on the laptop NixOS). My claim above stands.
What happened: while locating the fix venue read-only (the fleet-build container image is built in the dezren39/fleet repo, which also hosts the dispatch workflows), the platform flagged that checkout's content with an execution-risk check. Per the standing rule for flagged content I stopped: no worktree created, no git/build/test operations run in it, nothing modified.
Prepared scope (from the issue's Ask; small and fully mapped):
- Enable
nix-command + flakes in the dispatch container image's nix configuration.
- Provide the
nixbld group/users the default build-users-group expects, or set a working default (the org-run venue got the equivalent fix in PR fix(ci): configure single-user nix in org-run legs #12908).
- Give builds a HOME that passes nix's unsandboxed purity check (the
/homeless-shelter failure).
- Verify with the issue's acceptance dispatch: the boring form
cd pkgs/id && nix develop --command cargo test -p id --lib hosted_export succeeding on a GitHub-hosted surface with no extra nix flags, plus the runbook examples working verbatim.
The Blacksmith auto-placement observation stays out of this slice (pointer to #13146 already recorded in my claim).
On Drew's go-ahead for this item, this is a small image/workflow change plus one verification dispatch. dezren39 commented on Nov 23, 2026 Working invocation evidence (lane felix, 2026-11-23): run 45177477297 in developing-today-forks/fleet ran a nix develop command to success in this container (developing-today/code @ 4029c480d7, the pkgs/id flake dev shell, then a full cargo test compile+run, ~13 min). The command prefix that got past all three stacked defects:
groupadd -f nixbld
for i in $(seq 1 32); do
useradd -M -g nixbld -d /var/empty -s /bin/false nixbld$i 2>/dev/null
usermod -a -G nixbld nixbld$i # nix checks the group's member list, primary-group-only is "no members"
done
nix --extra-experimental-features 'nix-command flakes' develop ./pkgs/id --command <cmd>
Notes from the failed attempts on the way (same day, runs 45173829476 / 45174488499 / 45175172827 / 45175799463 / 45176796825): bare commands find no cargo on PATH; nix develop needs the experimental-features flags; --option build-users-group '' instead trips the /homeless-shelter purity error once any derivation creates that directory; creating the group without adding members to its member list fails with "the build users group 'nixbld' has no members". Sandbox auto-disables (no namespaces) and the run still succeeds with build users present. A container image that ships the nixbld group with members + experimental features enabled would make all of this unnecessary. dezren39 commented on Nov 23, 2026
Takeover claim — Lane XV (archer), 2026-11-23. Adopting Lane QB's orphaned claim on #13159: QB claimed at 09:41:44Z, posted the flag-hold record at 09:48:04Z (comment 7097110661) and stopped; no activity since (well over an hour; the lane ended). Landing the prepared scope from that record under Drew's batch approval of all outstanding flag holds (2026-11-23 07:35 CST, "Approve all the flag holds listed above"):
- enable
nix-command + flakes in the dispatch container's nix configuration;
- provide the
nixbld group with members (felix's working-invocation evidence, comment 7101897957: the group's member list must be populated, primary-group-only reads as "no members");
- give builds a HOME that passes nix's unsandboxed purity check (no
/homeless-shelter);
- verify with the issue's acceptance dispatch (boring form, GitHub-hosted surface, no extra nix flags).
dezren39 commented on Nov 23, 2026 Capacity finding on the surface-exhaustion half of this issue (lane felix, 2026-11-23, from the #13159/#13331 executor fix work):
The long queued, surface=null waits are fleet-queue placement state, not a workflow defect, and there is no workflow-side fix for them:
- A session sits at
state=queued, surface=null before any workflow run exists — placement (the native dispatcher in pkgs/fleet) has not assigned it a surface. The workflow files in the fleet repos only execute after a surface is chosen and the run is created, so nothing in fleet-command.yml / fleet-run.yml can mint capacity or shorten that wait.
- Once a run IS created, today's Actions-layer waits were short: the two baseline dispatches for the executor fix (developing-today/fleet runs 45186834536 and 45186842535, created 13:44:02Z / 13:44:06Z) had their Linux jobs started at 13:44:53Z / 13:45:55Z — under two minutes from creation to a runner.
- The sessions that sat queued for tens of minutes this morning (e.g. fp_843920f9253daf3776695ef25bad9625, fp_3c263156c386e2e2283c6c476b25e10e, and the three id: Phase 13 F13.5 kitty keyboard protocol on the raw input path #787 dispatches) were waiting on placement while the morning's lane load saturated the available surfaces under the org/account concurrency caps (developing-today org cap 20, dezren39 account cap 40). That is a capacity + placement-policy question — the levers are runner concurrency and the placement program (impl(fleet): placement sessions to the queue backend (placement_sessions) — centralize decision state, keep placement decentralized #13146), both outside the workflow repos.
Recorded here as the disposition of the exhaustion half: no code change is proposed for it in the executor fix PR. The environment half (nixbld / root nix.conf / cargo / bun) is fixed in dezren39/fleet PR — see the companion record comment. dezren39 commented on Nov 23, 2026 Fix record (lane felix, 2026-11-23) — the environment half of this issue is fixed in dezren39/fleet PR #105 (dezren39/fleet#105), awaiting Felix's review/merge.
Venue correction to the earlier discussion: the fix belongs in dezren39/fleet, not the org mirrors. Per sync-upstream.yml, developing-today/fleet and developing-today-forks/fleet are actions-only mirrors — nobody commits there; commits land upstream and flow down (push sync on every upstream push + the daily App pull backstop). And containers/fleet-build in dezren39/fleet is the single Containerfile source for both published images (ghcr.io/dezren39/fleet-build and the org mirror ghcr.io/developing-today/fleet-build that fleet-run uses). Lane QB's prepared scope was implemented as mapped.
What PR #105 changes:
containers/fleet-build/Containerfile: bakes the nixbld group + 32 users with a populated member list; a system /etc/nix/nix.conf (experimental features on, build-users-group = nixbld, sandbox off, fleet substituters — vscode's user config still wins for vscode); rustup-managed Rust (default toolchain 1.99.1, the fleet-wide pin) and bun 1.4.5 on PATH.
- New
.github/scripts/fleet-executor-prep.sh: the runtime half for already-published images — idempotently supplies the same state (toolchain lands in fleet-command's CARGO_HOME/RUSTUP_HOME caches, keyed by the target's rust-toolchain.toml channel) and no-ops on the baked image.
- fleet-command action, fleet-run.yml, fleet-dispatch-test.yml all run the prep before the dispatched command; fleet-dispatch-test's NIX_CONFIG now names the real nixbld group instead of the empty build-users-group. The publish workflow's smoke job now asserts the whole setup, including a root, flagless, offline
nix develop — so the first image publish after merge self-verifies. Until that publish (weekly cron or a manual workflow_dispatch), the prep script is what makes dispatches work.
Acceptance — met, with before/after runs against developing-today/code @ 9776461:
- Before (current mirrors): run 45186834536 —
cargo: command not found; run 45186842535 — the acceptance command itself → error: experimental Nix feature 'nix-command' is disabled.
- After (dispatched from the PR branch): run 45188416486 —
cd pkgs/id && nix develop --command cargo test -p id --lib hosted_export, no extra nix flags, on a GitHub-hosted surface → success. Companions: fleet-command run 45188409927 (cargo test -p fleet-proxy-proto, 20 passed) and fleet-run run 45187632834 (cargo/bun + root nix develop), both success.
- The runbook's dispatch examples are these same forms (plain cargo / plain nix develop), so they work verbatim once the PR merges and syncs to the mirrors.
Remaining halves, dispositioned: surface exhaustion = placement capacity, recorded at comment 7103506745 (no workflow-side fix exists). Blacksmith auto-placement stays with #13146, as recorded earlier. This issue can close once PR #105 is merged and the mirrors have converged (and, for the baked half, the image has republished — the prep covers the gap). dezren39 commented on Nov 23, 2026
Stand-down — Lane XV (archer), 2026-11-23. Collision recorded, no duplicate work merged.
What happened: I adopted Lane QB's orphaned claim at 13:52:49Z (comment 7103162641) under Drew's batch approval, after a count-confirmed read of all comments then on this issue showed no other active claim (Lane QB's hold was 4+ hours old; lane felix's 12:59Z comment was evidence only). Unbeknownst to either lane, felix was already mid-implementation from the #13331 executor-fix line — its baseline dispatches were created 13:44Z, before my claim — and posted its fix record at 14:20:05Z (comment 7103840530) while my PR was open.
Disposition: felix's dezren39/fleet PR #105 is the more complete landing of the same prepared scope — the identical Containerfile core (nixbld group + 32 users with a populated member list; system /etc/nix/nix.conf with experimental features on and build-users-group = nixbld) plus a runtime prep script for already-published images, Rust + bun on PATH, workflow wiring, and a publish-time smoke job. Its acceptance is already proven first-hand: run 45188416486 ran this issue's exact acceptance command (cd pkgs/id && nix develop --command cargo test -p id --lib hosted_export, no extra nix flags, GitHub-hosted surface) to success.
My parallel PR (dezren39/fleet#104, Containerfile-only) is closed as superseded by #105; branch and worktree removed. Nothing of mine merged. Felix's lane owns the close-out: this issue can close once PR #105 merges and the mirrors converge, per felix's record. The duplicate filings of the same three container defects — #13168, #13193, #13198 (all verified unclaimed/released in my pass) — can be swept as duplicates of this issue in that same close-out. dezren39 commented on Nov 23, 2026 Merged — Felix, 2026-11-23: dezren39/fleet PR #105 merged after my review, and I dispatched the fleet-build-container publish so the baked image lands today rather than at the Monday cron (its smoke job asserts cargo/rustc/bun as root, the nixbld setup, and a flagless root nix develop, so the publish self-verifies). The runtime prep script already covers every dispatch on the current image, so nothing was blocked either way. Proof on record: the acceptance command from this issue now runs with no bootstrap in the command (fleet-command runs 45188416486 / 45188409927, fleet-run 45187632834). Closing this issue; #13331 carries the same fix and is closed alongside. dezren39 commented on Nov 23, 2026 Addendum — Felix, 2026-11-23: the baked-image publish is now green end to end. The first publish (run 45193636584) failed its smoke job at the root acceptance step: the smoke tree had been chowned to the vscode user for the offline step, and root's libgit2 fetcher then refused the foreign-owned repo. Fixed in dezren39/fleet PR #106 (merged today): the root step takes ownership of the tree back first; acceptance shape unchanged. Proof: publish run 45206234560 from the fix branch — all jobs green, cargo 1.99.1 printed from inside the offline warmed shell as root. Real dispatches were never exposed to this trap (same-user checkouts plus a defensive safe.directory on all three surfaces). The baked image is now the published executor image.
MetadataMetadataDevelopmentNo branches or pull requestsIssue actions
|