Self-hosted deployment of OpenClaw Mission Control with an integrated OpenClaw Gateway.
# 1. Clone with submodules
git clone --recursive https://github.com/your-username/openclaw-automation.git
cd openclaw-automation
# 2. Configure environment
cp .env.example .env
nano .env # Set your API keys and tokens
# 3. Initialize gateway pairing (one-time setup)
./scripts/init-pairing.sh
# 4. Start everything
docker compose up -dThat's it! Access the dashboard at http://localhost:3000
| Service | Port | Description |
|---|---|---|
| Frontend | 3000 | Mission Control dashboard |
| Backend | 8000 | REST API |
| Gateway | 18789 | OpenClaw Gateway (WebSocket) |
| PostgreSQL | 5432 | Database |
| Redis | 6379 | Queue/cache |
| Worker | - | Background jobs |
This setup includes two web interfaces:
Management platform for orchestrating work across multiple gateways and agents.
- Manage multiple gateways
- Create boards (projects/workflows)
- Assign tasks to agents
- Track work across teams
- Approval workflows and governance
Login: Use LOCAL_AUTH_TOKEN from .env
Built-in interface for direct interaction with the gateway's AI agent.
- Chat directly with the AI agent
- View agent workspace/files
- Monitor real-time agent activity
- Approve tool executions
Login: Use OPENCLAW_GATEWAY_TOKEN from .env
Note: First browser access requires pairing approval. Run
./scripts/approve-browser.shif prompted.
| Aspect | Mission Control | Gateway Control UI |
|---|---|---|
| URL | localhost:3000 | localhost:18789 |
| Scope | Multiple gateways | Single gateway |
| Use case | Work orchestration | Direct AI chat |
| Analogy | Project dashboard | Terminal |
Edit .env with your settings:
# Required: Auth token (generate with: openssl rand -base64 48)
LOCAL_AUTH_TOKEN=your-50-char-minimum-token
# Required: Gateway token (generate with: openssl rand -hex 32)
OPENCLAW_GATEWAY_TOKEN=your-gateway-token
# Required: LLM API (LiteLLM or OpenAI-compatible)
OPENAI_API_KEY=your-api-key
LITELLM_BASE_URL=https://your-llm-endpoint
# Optional: Model configuration
LITELLM_MODEL_1=gpt-4
LITELLM_MODEL_2=gpt-3.5-turboAll data survives container restarts:
./data/
├── postgres/ # Database
├── redis/ # Cache/queue
├── openclaw/ # Gateway data & agent workspaces
└── backend/ # Backend device identity
# Start
docker compose up -d
# Stop
docker compose down
# View logs
docker compose logs -f
# Rebuild after changes
docker compose up -d --build
# Full reset (WARNING: deletes all data)
docker compose down -v
rm -rf ./data
./scripts/init-pairing.sh
docker compose up -dThe init-pairing.sh script automates the gateway-backend pairing:
- Generates a cryptographic device identity for the backend
- Pre-approves it in the gateway's trusted devices list
- Both identities persist across restarts
This eliminates the manual "device pairing" step normally required when connecting Mission Control to a gateway.
┌──────────────┐ ┌──────────────┐ ┌──────────────┐
│ Frontend │────▶│ Backend │────▶│ Gateway │
│ :3000 │ │ :8000 │ │ :18789 │
└──────────────┘ └──────┬───────┘ └──────────────┘
│
┌────────────┼────────────┐
│ │ │
┌─────▼─────┐ ┌────▼────┐ ┌─────▼─────┐
│ PostgreSQL│ │ Redis │ │ Worker │
└───────────┘ └─────────┘ └───────────┘
# Health check
curl http://localhost:8000/healthz
# List gateways
curl -H "Authorization: Bearer $LOCAL_AUTH_TOKEN" \
http://localhost:8000/api/v1/gateways
# List boards
curl -H "Authorization: Bearer $LOCAL_AUTH_TOKEN" \
http://localhost:8000/api/v1/boardsFull API docs: http://localhost:8000/docs
Gateway connection fails
# Check gateway logs
docker compose logs gateway
# Re-run pairing setup
./scripts/init-pairing.sh
docker compose restart backend gatewayPermission errors
# Fix data directory ownership
docker run --rm -v ./data:/data alpine chown -R 1000:1000 /dataPort conflicts
# Change ports in .env
FRONTEND_PORT=3001
BACKEND_PORT=8001
GATEWAY_PORT=18790