Agent Harbor
Sandboxed execution environment and orchestration layer for AI coding agents.
Run AI coding agents safely in isolated environments with time-travel debugging, parallel execution, and complete session recording.
Why Agent Harbor?
AI coding agents can write, execute, and modify code. Without proper isolation, they can:
- Access sensitive files (SSH keys, credentials, API tokens)
- Make unintended changes to your system
- Conflict with each other when running in parallel
Agent Harbor solves these problems with a purpose-built execution layer.
Core Capabilities
Sandboxed Execution
Every agent runs in an isolated environment:
- Read-only baseline — Host filesystem is protected
- Copy-on-write overlay — Changes are captured, never written to your actual files
- Sensitive areas shielded — Credentials directories blocked by default
- Network isolation — Egress disabled by default, opt-in when needed
Parallel Agent Execution
Launch multiple agents on the same task and keep the best result:
- Each agent works in its own filesystem branch
- No conflicts between concurrent sessions
- Compare outputs and cherry-pick the best solution
Time-Travel Debugging
Rewind to any point in an agent’s session:
- Filesystem snapshots at logical boundaries (per command, per tool use)
- Branch from any snapshot with new instructions
- Compare execution paths across branches
Session Recording
Every session is captured for replay and analysis:
- Terminal I/O recording with exact visual playback
- Filesystem state at each snapshot point
- Branch points for intervention
Filesystem Snapshot Providers
| Provider | Platform | Description |
|---|---|---|
| ZFS | Linux | Native ZFS snapshots — instant, zero-copy |
| Btrfs | Linux | Native Btrfs subvolume snapshots |
| AgentFS | All | Cross-platform userspace CoW filesystem |
| Git | All | Git worktree-based isolation (fallback) |
Supported Agents
| Agent | Mode |
|---|---|
| Claude Code | CLI |
| OpenAI Codex | CLI, Cloud |
| GitHub Copilot | CLI |
| Google Gemini | CLI |
| Cursor | CLI, IDE |
Supported Terminal Environments
| Environment | Platform |
|---|---|
| tmux | Linux, macOS |
| zellij | Linux, macOS |
| iTerm2 | macOS |
| kitty | Linux, macOS |
| WezTerm | Linux, macOS |
| Tilix | Linux |
Quick Start
Install via Nix
nix profile install github:blocksense-network/agent-harborVerify installation
ah healthStart an agent
ah agent start --agent claude --prompt "Add unit tests"Or launch the interactive TUI
ahSee Installation for detailed setup and First Task for a complete walkthrough.