Repository navigation
fix: restore cloud worker Desktop on node-backed Crabbox workers - #126393
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
Codex review: needs maintainer review before merge. Reviewed August 19, 2026, 2:18 PM ET / 18:18 UTC. ClawSweeper reviewWhat this changesRestores Cloud Worker Desktop streaming and Browser/Terminal launch for node-backed Crabbox leases through a fenced private node transport. Regression provenancePossible regression — suspected (reviewed change). No predecessor PR is attributed. Merge readinessKeep open for normal protected-label review: the branch restores a shipped Cloud Worker Desktop capability that current main disables for node-backed Crabbox workers, with no concrete patch defect found. Priority: P2 Review scores
Verification
Live VerificationCommand: Result: PASS (completed) Assertions:
How this fits togetherCloud Worker Desktop connects a Crabbox-provisioned worker desktop to the Gateway and Control UI. Provider lease metadata selects either the existing SSH path or the new node-carried stream and launch path. flowchart LR
A[Crabbox profile] --> B[Cloud worker lease]
B --> C[Paired node]
C --> D[Gateway desktop carrier]
D --> E[Control UI desktop pane]
D --> F[Browser and Terminal launch]
Before merge
Agent review detailsSecurityNone. PR surfaceSource +1005, Tests +933, Docs +8, Config +8. Total +1954 across 36 files. View PR surface stats
Review metrics
Stored data modelPersistent data-model change detected: Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Merge after exact-head checks are green and protected-label review confirms the node-carried carrier is the intended canonical replacement for the obsolete SSH-only assumption. Do we have a high-confidence way to reproduce the issue? Yes—current main's node-only Crabbox lease lacks the SSH endpoint required by the desktop access path, so the reported failure is source-reproducible. Is this the best way to solve the issue? Yes—the node carrier is the appropriate repair because the provider is intentionally node-backed; restoring SSH or moving Crabbox launcher policy into core would violate the existing ownership boundary. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 03a48b5801e3. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
|
Land-ready on exact head Local proof:
Live proof on the exact packed candidate (
CI: run 32285892296 completed green on the exact head. ClawSweeper reviewed this exact head with no findings and sufficient live proof. The only visual caveat is a Crabbox AWS base-image duplicate |
|
Merged via squash.
|
…nclaw#126393) * fix(gateway): carry cloud worker desktops over nodes * fix(crabbox): restore node-backed worker desktops * refactor(crabbox): split worker provider owners
Follow-up to #121475.
What Problem This Solves
Fixes an issue where operators enabling the Cloud Worker Desktop lab could no longer provision or observe Crabbox desktops after cloud-worker execution converged on node transport. Crabbox still understood desktop-capable profiles, but the provider rejected them before allocation and Gateway observation required an SSH-backed environment, so the Labs feature was effectively disabled on current node-backed workers.
Why This Change Was Made
This restores one canonical node-only flow. Crabbox provisions XFCE/TigerVNC and advertises Browser/Terminal, while Gateway owns private node transport, one-use observer tickets, view-only filtering, controller arbitration, app-launch dispatch, and durable environment/lease/node/epoch fencing. Core stays provider-agnostic; Crabbox-specific setup, launchers, timeouts, and the packaged 1920×1080 wallpaper remain in the plugin.
The repair also makes
gateway.publicOriginthe canonical enrollment fallback, removes Doctor's obsolete destructive Desktop cleanup, and splits the enlarged Crabbox provider into focused machine-catalog, enrollment-bootstrap, and wallpaper owners rather than adding a max-lines exemption.AI-assisted implementation and review; I understand and verified the resulting ownership and security boundaries.
User Impact
Operators can enable Cloud Worker Desktop and get a live, authenticated Desktop pane for fresh AWS or Hetzner Crabbox workers without exposing RFB publicly or reintroducing SSH as the OpenClaw runtime carrier. Browser and Terminal launch into the same visible desktop, controller mode is explicit, view-only mode is server-enforced, and workers use a fresh lease-scoped Chrome profile with loopback CDP.
The generated worker wallpaper is packaged as a static plugin asset and rendered consistently on the live TigerVNC monitor:
Hetzner clean-machine proof
AWS clean-machine proof
The AWS image also surfaced a Crabbox base-image issue where two
xfce4-panelprocesses compete for the notification area; the node/RFB/Desktop flow remained healthy and the Hetzner image was clean.Evidence
Local source proof:
node scripts/run-vitest.mjs src/gateway/worker-environments/node-desktop-carrier.test.ts src/gateway/worker-environments/node-enrollment.test.ts src/gateway/worker-environments/environment-access.test.ts src/node-host/desktop-stream-command.test.ts src/node-host/invoke-worker-supervisor.test.ts src/gateway/desktop/node-observe.integration.test.ts extensions/crabbox/src/crabbox-worker-provider.test.ts extensions/crabbox/src/doctor.test.ts test/scripts/runtime-postbuild.test.ts— 225 tests passed across four shards.node scripts/run-vitest.mjs extensions/crabbox/src/crabbox-worker-provider.test.ts extensions/crabbox/src/doctor.test.ts— 115 tests passed after the provider ownership split.pnpm check:changed— passed all selected formatting, typecheck, lint, import-cycle, metadata, database, SDK-boundary, and guard lanes.pnpm build— passed; root and package-local wallpaper copies matched the source byte-for-byte at 753,513 bytes and 1920×1080.fd1106f9a7b400008bfcdbe6cd562095bc0a4a2695a46e51fc4d9736286121fc.Fresh live DevGateway proof on the exact candidate:
404and authenticated200.c7a.8xlarge) and Hetzner (ccx33) environments reachedready, advertised Desktop plus only Browser/Terminal, and persistednodeBacked=true,sshBacked=false.status=readyon both providers.127.0.0.1:5900and[::1]:5900on both workers.instanceProfileAttached=false./focus/desktopcaptures reportedconnected, one framebuffer canvas, the exact environment source, andcontrolling=truein controller mode /controlling=falsein view-only mode for both providers.