Cross-platform container runner with Claude Code and Playwright support
Run your projects in isolated containers using Podman. Works on Windows, macOS, and Linux.
No installation required! Podman binaries auto-download on first use:
npx sandboxbox build
npx sandboxbox run ./my-project
SandboxBox automatically downloads portable Podman binaries when you run it:
- ✅ Windows - Downloads podman.exe (v4.9.3)
- ✅ macOS - Downloads podman remote client
- ✅ Linux - Downloads static podman binary
Just like sqlite or Playwright, no manual installation needed!
If you prefer to install Podman system-wide:
Windows:
winget install RedHat.Podman
macOS:
brew install podman
podman machine init
podman machine start
Linux:
sudo apt-get install podman # Ubuntu/Debian
sudo dnf install podman # Fedora
sudo apk add podman # Alpine
npx sandboxbox build
This builds a container with:
- Node.js v22
- Claude Code CLI
- Playwright with all browser dependencies
- Git, npm, and essential build tools
# Run with default shell
npx sandboxbox run ./my-project
# Run custom command
npx sandboxbox run ./my-project "npm test"
# Run Claude Code
npx sandboxbox run ./my-project "claude --help"
# Run Playwright tests
npx sandboxbox run ./my-project "npx playwright test"
npx sandboxbox shell ./my-project
- Windows - Full support with Podman Desktop
- macOS - Works with Podman machine
- Linux - Native Podman support
- Complete container isolation
- Your host system stays clean
- Workspace mounted at
/workspace
- Node.js v22
- Claude Code CLI - AI-powered development
- Playwright - Browser automation with all dependencies
- Git - Version control
- npm - Package management
- No global installation needed
- Single command execution
- Works with any project directory
# Build container from Dockerfile
npx sandboxbox build
npx sandboxbox build ./Dockerfile.custom
# Run project in container
npx sandboxbox run <project-dir> [command]
# Interactive shell
npx sandboxbox shell <project-dir>
# Show version
npx sandboxbox version
- Builds a container image from the Dockerfile using Podman
- Mounts your project directory to
/workspace
in the container - Runs your command in the isolated container environment
- Removes the container automatically when done
Your Project Container
./my-project ━━━━━> /workspace
(host) (isolated)
npx sandboxbox run ./my-app "claude --version"
npx sandboxbox run ./my-app "claude code review lib/"
npx sandboxbox run ./my-app "npx playwright test"
npx sandboxbox run ./my-app "npx playwright test --headed"
# Build once
npx sandboxbox build
# Interactive development
npx sandboxbox shell ./my-app
# Inside container:
npm install
npm test
git commit -am "Update"
exit
npx sandboxbox run ./my-app "npm run build"
npx sandboxbox run ./my-app "npm run lint"
npx sandboxbox run ./my-app "npm run test:e2e"
Create your own Dockerfile
:
FROM node:22-alpine
# Install system dependencies
RUN apk add --no-cache git bash curl
# Install global packages
RUN npm install -g @anthropic-ai/claude-code @playwright/test
# Install Playwright browsers
RUN npx playwright install --with-deps chromium
WORKDIR /workspace
CMD ["/bin/bash"]
Then build:
npx sandboxbox build ./Dockerfile
- Podman (https://podman.io/getting-started/installation)
- Node.js 16+ (for running npx)
sandboxbox/
├── cli.js # Main CLI - Podman integration
├── Dockerfile # Container definition
├── package.json # NPM package config
└── README.md # This file
- ✅ Cross-platform - Works on Windows, macOS, Linux
- ✅ Rootless - No daemon, runs as regular user
- ✅ Docker-compatible - Uses OCI standard containers
- ✅ Secure - Better security model than Docker
- ✅ Fast - Lightweight and efficient
v1.x (bubblewrap):
- Linux-only
- Required bubblewrap installation
- Direct process isolation
v2.x (Podman):
- Cross-platform (Windows/macOS/Linux)
- Uses Podman containers
- OCI-standard container images
- More portable and widely supported
MIT
Contributions welcome! This project focuses on cross-platform container execution with Claude Code and Playwright support using Podman.