Claude Code Docker Sandbox

Set up a Docker Compose-isolated development environment where dependency installs and agent-run code execute behind a default-deny network firewall, never touching the host. Use when you want to run `npm install` / `cargo build` / `cabal build` / `go build`, untrusted dependencies, or Claude Code itself in a container to contain supply-chain attacks — without depending on VS Code. Reuses Anthropic's published devcontainer Dockerfile + init-firewall.sh, driven by a plain docker-compose.yml so any host editor works via bind mount; Rust/Haskell/Go toolchains are opt-in build args on the node:24 (LTS) base. Covers the egress allowlist (fatal vs OPTIONAL non-fatal domains), build-time-vs-runtime network, keeping Claude Code current inside the firewall (native updater's host is blocked — update via npm at start), why the /model picker hides flag-gated models until DISABLE_TELEMETRY is unset, bypassPermissions-by-default (container-scope, not repo-shared), and host-side git hygiene.

okayus 56b35b4 7 files · 49.8 KB Updated

File contents

okayus/okayus-skills/tree/main/skills/claude-code-docker-sandbox commit 56b35b4bf6

Frequently asked questions

npx skillmds@latest add okayus/claude-code-docker-sandbox