Self-Hosting with Docker Compose
The repository includes a production-ready docker-compose.yml stack featuring:
- Application Server (
app): FastAPI backend, Vite-built frontend, and async background worker running in a single container. - Caddy Reverse Proxy (
caddy): Automatic HTTPS (Let’s Encrypt / ZeroSSL), HTTP/3 support, and unbuffered SSE streaming for live LLM tokens. - Flexible Database Choices: Built-in persistent SQLite by default (zero setup), or connect to any PostgreSQL database (Supabase, Neon, AWS RDS, Cloud SQL, or bundled local Postgres).
1. Clone & Configure
Section titled “1. Clone & Configure”git clone https://github.com/kcthota/scout.gitcd scoutcp .env.example .env
# Generate required secure secrets in .env:sed -i.bak "s|replace_with_32_hex_session_secret|$(openssl rand -hex 32)|" .envsed -i.bak "s|replace_with_base64_encryption_key|$(openssl rand -base64 32)|" .env && rm -f .env.bakAdd your GOOGLE_API_KEY (or GEMINI_API_KEY) in .env. Gemini is always required because embeddings, conversation compaction, and voice transcription use it.
The application will refuse to start if SESSION_SECRET or ENCRYPTION_KEY are left as placeholders. Telegram and Email channels can be configured after startup in the web UI.
2. Choose Your Image & Deployment Method
Section titled “2. Choose Your Image & Deployment Method”Option A: Pre-Built Container Image from GHCR (Recommended)
Section titled “Option A: Pre-Built Container Image from GHCR (Recommended)”No local build tools or language runtimes needed. Scout publishes official Docker images to GitHub Container Registry (ghcr.io/kcthota/scout).
- If the GHCR package is private, authenticate Docker once with a GitHub Personal Access Token (
read:packagesscope):Terminal window echo "<YOUR_GITHUB_TOKEN>" | docker login ghcr.io -u <YOUR_GITHUB_USERNAME> --password-stdin - Pull the latest image:
Terminal window docker compose pull - To pin a specific release version, set
APP_IMAGEin your.env:APP_IMAGE=ghcr.io/kcthota/scout:v0.1.0
Option B: Build from Source Locally
Section titled “Option B: Build from Source Locally”To build the container image locally from the repository Dockerfile:
docker compose up -d --build3. Choose Your Database in .env
Section titled “3. Choose Your Database in .env”Scout supports four database configurations out of the box:
Option A: Built-in SQLite (Default, Zero-Setup)
Section titled “Option A: Built-in SQLite (Default, Zero-Setup)”No extra configuration required. The SQLite database (scout.db) and uploaded media are stored in /app/data (persisted in the app_data Docker volume), and Goose conversation history and session continuity are persisted in the goose_data Docker volume:
DATABASE_URL=sqlite+aiosqlite:////app/data/scout.dbSQLite automatically uses the bundled sqlite-vec extension for fast indexed vector search across memories and knowledge documents.
Option B: External Cloud PostgreSQL
Section titled “Option B: External Cloud PostgreSQL”Set DATABASE_URL pointing to your hosted PostgreSQL instance (Supabase, Neon, AWS RDS, Cloud SQL Direct, etc.):
Option C: Bundled Local PostgreSQL Container
Section titled “Option C: Bundled Local PostgreSQL Container”To run a local PostgreSQL container (pgvector/pgvector:pg16) inside Docker Compose instead of SQLite, enable the local-db profile:
COMPOSE_PROFILES=local-dbDATABASE_URL=postgresql+asyncpg://postgres:replace_with_a_secure_password@postgres:5432/scoutPOSTGRES_USER=postgresPOSTGRES_PASSWORD=replace_with_a_secure_passwordPOSTGRES_DB=scoutOption D: Google Cloud SQL Auth Proxy
Section titled “Option D: Google Cloud SQL Auth Proxy”To connect to Google Cloud SQL using IAM / Auth Proxy sidecar container, enable the cloudsql profile:
COMPOSE_PROFILES=cloudsqlCLOUDSQL_CONNECTION_NAME=your-gcp-project:region:instance-nameGOOGLE_APPLICATION_CREDENTIALS=/path/to/service-account-key.jsonPOSTGRES_HOST=cloudsql-proxyPOSTGRES_USER=postgresPOSTGRES_PASSWORD=your_cloudsql_passwordPOSTGRES_DB=scout4. Launch Services
Section titled “4. Launch Services”docker compose up -dAccess your agent at https://your-domain.com (or http://localhost when testing locally with DOMAIN=:80).
5. Upgrading
Section titled “5. Upgrading”To upgrade to the latest container release:
docker compose pull appdocker compose up -dDatabase schema migrations apply automatically on container startup (alembic upgrade head).
Container Registry & Versioning Reference
Section titled “Container Registry & Versioning Reference”Scout Docker images are published to GitHub Container Registry at ghcr.io/kcthota/scout:
| Tag | Description |
|---|---|
latest |
Latest stable release |
vX.Y.Z (e.g. v0.1.0) |
Specific immutable release tag |
vX.Y (e.g. v0.1) |
Latest patch release for minor version X.Y |
Automated image publishing is handled by GitHub Actions (.github/workflows/publish-docker.yml) whenever a version tag (v*) is pushed to the repository.
