# Production Configuration A complete Gordon configuration for production environments. ## When to Use - Production deployments - Multiple applications - Services requiring databases ## Configuration ```toml # ~/.config/gordon/gordon.toml # Server settings [server] port = 8080 # Cloudflare forwards 443 → 8080 registry_port = 5000 gordon_domain = "gordon.company.com" # Authentication with pass backend (recommended) [auth] enabled = true secrets_backend = "pass" token_secret = "gordon/auth/token_secret" # File-based logging with rotation [logging] level = "info" format = "json" [logging.file] enabled = true path = "~/.gordon/logs/gordon.log" max_size = 100 max_backups = 10 max_age = 90 [logging.container_logs] enabled = true # enabled by default dir = "~/.gordon/logs/containers" max_size = 100 max_backups = 10 max_age = 90 # Environment directory [env] dir = "~/.gordon/env" # Volume settings (all enabled by default) [volumes] auto_create = true prefix = "gordon" preserve = true # Network isolation for security [network_isolation] enabled = true network_prefix = "prod" # Application routes with pinned versions [routes] "app.company.com" = "company-app:v2.1.0" "api.company.com" = "company-api:v1.5.2" "admin.company.com" = "admin-panel:v1.0.1" "docs.company.com" = "company-docs:latest" # Network groups for shared services [network_groups] "backend" = ["app.company.com", "api.company.com"] # Service attachments [attachments] "backend" = ["company-redis:latest"] "app.company.com" = ["company-postgres:latest"] "api.company.com" = ["company-postgres:latest"] ``` ## Setup Steps ### 1. Install Pass ```bash sudo apt install pass gnupg gpg --gen-key pass init your-gpg-key-id ``` ### 2. Store Token Secret ```bash # Generate random secret openssl rand -base64 32 | pass insert -m gordon/auth/token_secret ``` ### 3. Generate CI Token ```bash gordon auth token generate --subject ci-bot --scopes push,pull --expiry 0 ``` ### 4. Create Environment Files ```bash # App environment cat > ~/.gordon/env/app_company_com.env < ~/.gordon/env/api_company_com.env <