Docker
Docker Compose is the recommended way to run Clawbolt. It handles the app and tunnel setup.
Quick start
Section titled “Quick start”# Clone and configuregit clone https://github.com/mozilla-ai/clawbolt.gitcd clawboltcp .env.example .env# Edit .env with your credentials
# Start everythingdocker compose up --buildWhat Docker Compose starts
Section titled “What Docker Compose starts”| Service | Description |
|---|---|
| app | FastAPI server on port 8000 |
| db | PostgreSQL database for all structured data |
| tunnel | Cloudflare Tunnel for HTTPS webhook registration |
On startup, the app:
- Runs database migrations automatically
- Starts the FastAPI server
- Auto-registers webhooks via the Cloudflare Tunnel URL (Telegram and, if Linq is the configured iMessage backend, Linq)
Data persistence
Section titled “Data persistence”Structured data (users, messages, memory, etc.) is stored in PostgreSQL. The Docker Compose file includes a PostgreSQL service with a named volume for persistence.
File uploads and media are stored under the data/ directory. By default, Docker Compose bind-mounts ./data from your host into the container at /app/data.
Verify it’s running
Section titled “Verify it’s running”curl http://localhost:8000/api/health# {"status":"ok"}Troubleshooting
Section titled “Troubleshooting”Docker build fails with dependency errors
Section titled “Docker build fails with dependency errors”Try rebuilding without cache:
# Rebuild without cachedocker compose build --no-cachePort 8000 already in use
Section titled “Port 8000 already in use”# Stop existing containersdocker compose down
# Or use a different portdocker compose up --build -e APP_PORT=8080Reset all data
Section titled “Reset all data”# Remove all user datarm -rf data/users/docker compose up --build