




























@@ -0,0 +1,78 @@
1+---
2+name: crabbox
3+description: Use Crabbox for OpenClaw remote Linux validation, warmed reusable boxes, GitHub Actions hydration, sync timing, logs, results, caches, and lease cleanup.
4+---
5+6+# Crabbox
7+8+Use Crabbox when OpenClaw needs remote Linux proof on owned capacity, a large
9+runner class, reusable warm state, or a Blacksmith alternative.
10+11+## Before Running
12+13+- Run from the repo root. Crabbox sync mirrors the current checkout.
14+- Prefer local targeted tests for tight edit loops.
15+- Prefer Blacksmith Testbox when the task explicitly asks for Blacksmith or a
16+ Blacksmith-specific CI comparison.
17+- Use Crabbox for broad OpenClaw gates when owned AWS/Hetzner capacity is the
18+ right remote lane.
19+- Check `.crabbox.yaml` for repo defaults before adding flags.
20+- Install with `brew install openclaw/tap/crabbox`; auth is required before use: `crabbox login`.
21+22+## OpenClaw Flow
23+24+Warm a reusable box:
25+26+```sh
27+pnpm crabbox:warmup -- --idle-timeout 90m
28+```
29+30+Hydrate it through the repository workflow:
31+32+```sh
33+pnpm crabbox:hydrate -- --id <cbx_id-or-slug>
34+```
35+36+Run broad proof:
37+38+```sh
39+pnpm crabbox:run -- --id <cbx_id-or-slug> --shell "OPENCLAW_TESTBOX=1 pnpm check:changed"
40+pnpm crabbox:run -- --id <cbx_id-or-slug> --shell "corepack enable && pnpm install --frozen-lockfile && pnpm test"
41+```
42+43+Stop boxes you created before handoff:
44+45+```sh
46+pnpm crabbox:stop -- <cbx_id-or-slug>
47+```
48+49+## Useful Commands
50+51+```sh
52+crabbox status --id <id-or-slug> --wait
53+crabbox inspect --id <id-or-slug> --json
54+crabbox sync-plan
55+crabbox history --lease <id-or-slug>
56+crabbox logs <run_id>
57+crabbox results <run_id>
58+crabbox cache stats --id <id-or-slug>
59+crabbox ssh --id <id-or-slug>
60+```
61+62+Use `--debug` on `run` when measuring sync timing.
63+64+## Hydration Boundary
65+66+`.github/workflows/crabbox-hydrate.yml` is repo-specific on purpose. It owns
67+OpenClaw checkout, setup-node, pnpm setup, provider env hydration, ready marker,
68+and keepalive. Crabbox owns runner registration, workflow dispatch, SSH sync,
69+command execution, logs/results, local lease claims, and idle cleanup.
70+71+Do not add OpenClaw-specific setup to Crabbox. Put repo setup in the hydration
72+workflow and generic lease/sync behavior in Crabbox.
73+74+## Cleanup
75+76+Crabbox has coordinator-owned idle expiry and local lease claims, so OpenClaw
77+does not need a custom ledger. Default idle timeout is 30 minutes unless config
78+or flags set a different value. Still stop boxes you created when done.
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。