nerdicbynature

AI Sandbox Macosx — DevOps skill for Claude Code

DevOps community

Hardened Docker Compose sandbox for AI coding agents (Claude Code, OpenCode, Copilot CLI).

How to install AI Sandbox Macosx

This entry records only its repository, not the path inside it, so there is no exact command to give. Open nerdicbynature/ai-sandbox-macosx and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

What AI Sandbox Macosx does

Hardened Docker Compose sandbox for AI coding agents (Claude Code, OpenCode, Copilot CLI). Non-root, no capabilities, read-only rootfs, internal-only network: all traffic goes through mitmproxy so you can inspect every HTTPS request. Tokens from the macOS Keychain. Includes Go/Kubernetes and Python variants.

Alternatives in DevOps

  • Kubeshark — Cluster-wide network observability for Kubernetes 11.8k ★
  • Mirrord — Run any process, on your machine or in an AI agent's environment, as if it were a pod in your Kubernetes clust 5.3k ★
  • Cccc — Coordinate your coding agents like a group chat — read receipts, delivery tracking, and remote ops from your p 1.1k ★

README

AI Sandbox (Docker Compose, Rancher Desktop on macOS)

An isolated workspace for **Claude Code**, **OpenCode** and **GitHub Copilot CLI**. The sandbox has no internet access of its own. Every request goes through a **mitmproxy** that terminates TLS, so you can watch every HTTP(S) request live.

 Mac (Rancher Desktop / dockerd)
 ┌────────────────────────────────────────────────────────────────────┐
 │  network "sandbox-net" (internal: no gateway, no internet)         │
 │  ┌──────────────────────┐   HTTP(S)_PROXY    ┌──────────────────┐  │
 │  │ sandbox              │ ─────────────────▶ │ proxy (mitmweb)  │──┼──▶ internet
 │  │ user dev, cap_drop   │      :8080         │ network "egress" │  │
 │  │ read-only rootfs     │                    │ UI :8081 ────────┼──┼──▶ http://localhost:8081
 │  │ /workspace ◀─ ~/dev  │ ◀── CA certificate (public only, ro) ─│  │
 │  └──────────────────────┘                    └──────────────────┘  │
 └────────────────────────────────────────────────────────────────────┘

Contents

Path Purpose
docker-compose.yml Proxy, sandbox and the sub-sandboxes (profiles go, python)
sandbox/ Sandbox image: node:lts-bookworm-slim + dev/debug tools + gh + the three harnesses
proxy/ mitmproxy image + addon (CA export, access log, allowlist, TLS passthrough)
scripts/keychain-env.sh Loads tokens from the macOS Keychain as env vars into the current bash shell
scripts/keychain-store.sh Stores tokens in the Keychain
config/claude, config/opencode, config/copilot Default configs, mounted to ~/.claude, ~/.config/opencode, ~/.copilot
images/go-k8s, images/python Sub-sandboxes built on top of the sandbox image

**Why a Node base image?** Claude Code, Copilot CLI and the OpenCode installer are all distributed via npm (Copilot CLI needs Node ≥ 22). `node:lts-bookworm-slim` is Debian, so `apt` works as usual. Swap the base via the build arg `BASE_IMAGE` (e.g