# Docker Install

Docker is the fastest way to run `sandboxed.sh` (the former name of the project, now the backend to the **Orb** clients) and the web admin console on Linux, macOS, or Windows. The image bundles the Rust backend (`sandboxed-sh`), MCP companions (`sandboxed-mcp`, `workspace-mcp`, `desktop-mcp`), the Next.js web console, Caddy, and primary agent CLIs.

## Quick Start

```bash
git clone https://github.com/Th0rgal/orb.git
cd orb
cp .env.example .env
# Edit .env: set DASHBOARD_PASSWORD and JWT_SECRET
docker compose up -d
```

- **Web Console & API**: `http://localhost:3000`
- **Orb Desktop / iOS**: Connect to `http://localhost:3000` (or your TLS domain) using `DASHBOARD_PASSWORD`.

## Essential Configuration (`.env`)

| Variable | Description |
| --- | --- |
| `DEV_MODE` | Set to `false` in production to enforce password/JWT authentication |
| `DASHBOARD_PASSWORD` | Password for Orb and web login |
| `JWT_SECRET` | Long random secret used to sign JWT tokens |
| `SANDBOXED_SH_USERS` | Optional JSON array for multi-user authentication |
| `LIBRARY_REMOTE` | Git URL for your shared Library repository |
| `MAX_PARALLEL_MISSIONS` | Maximum concurrent server missions |

## Container Workspaces (`systemd-nspawn`)

By default, workspaces inside Docker execute in host/fallback mode inside the container. To enable full per-workspace `systemd-nspawn` container isolation, uncomment the privileged settings in `docker-compose.yml`:

```yaml
services:
  sandboxed-sh:
    privileged: true
    cgroup: host
```

Then restart:

```bash
docker compose down && docker compose up -d
```

## Persistent Volumes

- `sandboxed-data` (`/root/.sandboxed-sh`): SQLite databases (`missions.db`, `projects.db`, `ask.db`), Library checkout, synchronized `@context` files, and container rootfs trees.
- `claude-auth` (`/root/.claude`): Legacy Claude credentials when not using CLIProxyAPI.
- `~/.ssh:/root/.ssh:ro`: Read-only mount of host SSH keys (copied to a writable key dir at startup for private Git repositories).