Self-Hosting
Self-Hosting Overview
Run QUESTPIE Autopilot on your own infrastructure for full data sovereignty and control.
Run Autopilot on your own servers. Your data never leaves your network.
Why Self-Host
- Data sovereignty — all company data, agent sessions, and secrets stay on your infrastructure
- Air-gapped environments — run behind firewalls with no inbound internet access (only outbound to Anthropic API)
- Custom infrastructure — integrate with existing monitoring, backup, and access control systems
- Compliance — meet regulatory requirements that prohibit SaaS data processing
Architecture
┌─────────────────────────────────────┐
│ Orchestrator (Bun) │
│ │
CLI / Dashboard ──┤ :7778 REST API + SSE + Dashboard │
│ │
GitHub / Slack ──┤ :7777 Webhook Server │
│ │
│ ┌──────────┐ ┌──────────────────┐ │
│ │ Watcher │ │ Scheduler (cron) │ │
│ └──────────┘ └──────────────────┘ │
│ ┌──────────┐ ┌──────────────────┐ │
│ │ Sessions │ │ Workflow Engine │ │
│ └──────────┘ └──────────────────┘ │
│ │
│ SQLite (.data/autopilot.db) │
│ Company filesystem (YAML/MD) │
└─────────────────────────────────────┘
│
▼
Anthropic Claude APIOne Bun process. One SQLite file. No external databases.
Prerequisites
| Requirement | Version | Notes |
|---|---|---|
| Bun | 1.3+ | Runtime (or use Docker instead) |
| Git | 2.x+ | Company state versioning |
| Authentication | — | autopilot provider set openrouter --api-key sk-or-... (subscription, recommended) or OPENROUTER_API_KEY (API key) |
Choose Your Path
Docker (recommended for production)
Fastest path to a running instance. No Bun installation needed on the host.
terminal
# Initialize a company directory
docker run --rm -v $(pwd):/out questpie/autopilot:latest \
autopilot init my-company --output /out/my-company
# Start the orchestrator
docker compose up -dFull guide: Docker Deployment
Bare Metal
Run directly with Bun. Best for development or when you want full control.
terminal
bun add -g @questpie/autopilot
autopilot init my-company
cd my-company
# Authenticate (choose one)
autopilot provider set openrouter --api-key sk-or-... # Use Claude subscription (recommended)
# OR
export OPENROUTER_API_KEY=sk-or-... # Use API key
autopilot startFull guide: Bare Metal Deployment
Next Steps
- Configuration Reference — full company.yaml schema and environment variables
- Networking — reverse proxy, TLS, Tailscale, webhook tunneling
- Authentication — enable auth, create users, manage roles
- Secrets — master key, encrypted credentials