docs: clarify sandbox env + recreate guidance
This commit is contained in:
@@ -105,6 +105,11 @@ Build it once:
|
||||
scripts/sandbox-setup.sh
|
||||
```
|
||||
|
||||
Note: the default image does **not** include Node. If a skill needs Node (or
|
||||
other runtimes), either bake a custom image or install via
|
||||
`sandbox.docker.setupCommand` (requires network egress + writable root +
|
||||
root user).
|
||||
|
||||
Sandboxed browser image:
|
||||
```bash
|
||||
scripts/sandbox-browser-setup.sh
|
||||
@@ -129,6 +134,8 @@ Common pitfalls:
|
||||
- Default `docker.network` is `"none"` (no egress), so package installs will fail.
|
||||
- `readOnlyRoot: true` prevents writes; set `readOnlyRoot: false` or bake a custom image.
|
||||
- `user` must be root for package installs (omit `user` or set `user: "0:0"`).
|
||||
- Sandbox exec does **not** inherit host `process.env`. Use
|
||||
`agents.defaults.sandbox.docker.env` (or a custom image) for skill API keys.
|
||||
|
||||
## Tool policy + escape hatches
|
||||
Tool allow/deny policies still apply before sandbox rules. If a tool is denied
|
||||
|
||||
@@ -87,6 +87,17 @@ WhatsApp + Telegram channels require **Node**; Bun is unsupported. If your
|
||||
service was installed with Bun or a version-managed Node path, run `clawdbot doctor`
|
||||
to migrate to a system Node install.
|
||||
|
||||
### Skill missing API key in sandbox
|
||||
|
||||
**Symptom:** Skill works on host but fails in sandbox with missing API key.
|
||||
|
||||
**Why:** sandboxed exec runs inside Docker and does **not** inherit host `process.env`.
|
||||
|
||||
**Fix:**
|
||||
- set `agents.defaults.sandbox.docker.env` (or per-agent `agents.list[].sandbox.docker.env`)
|
||||
- or bake the key into your custom sandbox image
|
||||
- then run `clawdbot sandbox recreate --agent <id>` (or `--all`)
|
||||
|
||||
### Service Running but Port Not Listening
|
||||
|
||||
If the service reports **running** but nothing is listening on the gateway port,
|
||||
|
||||
Reference in New Issue
Block a user