{
  "manifest_version": "1.0.0",
  "template": {
    "id": "43289339-a7e5-454a-af6c-b81643e08a54",
    "slug": "deploy-openpanel-vs-plausible",
    "name": "OpenPanel vs Plausible",
    "description": "Product analytics vs simple cookieless web stats",
    "url": "https://railway.com/deploy/deploy-openpanel-vs-plausible",
    "upstream": {
      "image": "caddy:2-alpine@sha256:d8542f48d34a9cf4e4c11a478865229840e87e4c96ea3f439101f31a5d35f75f"
    }
  },
  "services": [
    {
      "name": "op-worker",
      "source": {
        "image": "lindesvard/openpanel-worker:2.3.0@sha256:b22e247fb6980b820c1a954d0e3d2fe88b3edf40a58aa53329467af239538e80"
      },
      "needs_volume": false,
      "http": false
    },
    {
      "name": "op-postgres",
      "source": {
        "image": "ghcr.io/railwayapp-templates/postgres-ssl:17"
      },
      "needs_volume": true,
      "volume_mount_path": "/var/lib/postgresql/data",
      "http": false
    },
    {
      "name": "op-proxy",
      "source": {
        "image": "caddy:2-alpine@sha256:d8542f48d34a9cf4e4c11a478865229840e87e4c96ea3f439101f31a5d35f75f"
      },
      "needs_volume": false,
      "http": true
    },
    {
      "name": "op-dashboard",
      "source": {
        "image": "lindesvard/openpanel-dashboard:2.3.0@sha256:b773cf864454a0ec89b2a133b48bf06202880ed650a75cc2f1f5c87aaed1cffa"
      },
      "needs_volume": false,
      "http": false
    },
    {
      "name": "op-clickhouse",
      "source": {
        "image": "clickhouse/clickhouse-server:25.12@sha256:8a790dd3468db22b1d4e7b18a176f378ff5ff6053b9c48dd4ea1fa71a24c5ba6"
      },
      "needs_volume": true,
      "volume_mount_path": "/var/lib/clickhouse",
      "http": false
    },
    {
      "name": "op-redis",
      "source": {
        "image": "redis:8.2.1@sha256:5fa2edb1e408fa8235e6db8fab01d1afaaae96c9403ba67b70feceb8661e8621"
      },
      "needs_volume": true,
      "volume_mount_path": "/data",
      "http": false
    },
    {
      "name": "op-api",
      "source": {
        "image": "lindesvard/openpanel-api:2.3.0@sha256:cee4855cd715a7248c5c49090fe93a28ffc505541de20cb238d8884a6bcb9223"
      },
      "needs_volume": false,
      "http": false
    }
  ],
  "required_inputs": [
    {
      "key": "PORT",
      "service": "op-worker",
      "description": "HTTP port for this service (3000).",
      "secret": false,
      "strategy": "default",
      "default": "3000"
    },
    {
      "key": "API_URL",
      "service": "op-worker",
      "description": "Public API URL: op-proxy domain plus /api.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "API_HOST",
      "service": "op-worker",
      "description": "Listen on :: so Railway IPv6 private networking works.",
      "secret": false,
      "strategy": "default",
      "default": "::"
    },
    {
      "key": "REDIS_URL",
      "service": "op-worker",
      "description": "Redis URL with password on op-redis private domain.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "SELF_HOSTED",
      "service": "op-worker",
      "description": "Enables self-hosted mode (true).",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "DATABASE_URL",
      "service": "op-worker",
      "description": "Postgres connection string from op-postgres.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "COOKIE_SECRET",
      "service": "op-worker",
      "description": "Signs session cookies; generated on op-api and shared.",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "DASHBOARD_URL",
      "service": "op-worker",
      "description": "Public dashboard URL on the op-proxy domain.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "CLICKHOUSE_URL",
      "service": "op-worker",
      "description": "ClickHouse HTTP URL for the openpanel database.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "ALLOW_INVITATION",
      "service": "op-worker",
      "description": "Allow inviting teammates by email.",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "ALLOW_REGISTRATION",
      "service": "op-worker",
      "description": "Allow sign-up; closes after the first user.",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "DATABASE_URL_DIRECT",
      "service": "op-worker",
      "description": "Direct Postgres URL used for migrations.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "PGDATA",
      "service": "op-postgres",
      "description": "Data directory inside the volume.",
      "secret": false,
      "strategy": "default",
      "default": "/var/lib/postgresql/data/pgdata"
    },
    {
      "key": "PGHOST",
      "service": "op-postgres",
      "description": "Private hostname of the Postgres service.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "PGPORT",
      "service": "op-postgres",
      "description": "Postgres port (5432).",
      "secret": false,
      "strategy": "default",
      "default": "5432"
    },
    {
      "key": "PGUSER",
      "service": "op-postgres",
      "description": "Postgres username used by clients; references POSTGRES_USER.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PGDATABASE",
      "service": "op-postgres",
      "description": "Postgres database name; references POSTGRES_DB.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PGPASSWORD",
      "service": "op-postgres",
      "description": "Postgres password; references POSTGRES_PASSWORD.",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "POSTGRES_DB",
      "service": "op-postgres",
      "description": "Database created on first boot (railway).",
      "secret": false,
      "strategy": "default",
      "default": "railway"
    },
    {
      "key": "DATABASE_URL",
      "service": "op-postgres",
      "description": "Private connection string used by the apps.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "POSTGRES_USER",
      "service": "op-postgres",
      "description": "Postgres superuser (postgres).",
      "secret": false,
      "strategy": "default",
      "default": "postgres"
    },
    {
      "key": "SSL_CERT_DAYS",
      "service": "op-postgres",
      "description": "Validity in days of the self-signed SSL certificate.",
      "secret": false,
      "strategy": "default",
      "default": "820"
    },
    {
      "key": "POSTGRES_PASSWORD",
      "service": "op-postgres",
      "description": "Postgres password, generated per deploy.",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "PORT",
      "service": "op-proxy",
      "description": "Caddy listen port and public target port (8080).",
      "secret": false,
      "strategy": "default",
      "default": "8080"
    },
    {
      "key": "API_URL",
      "service": "op-proxy",
      "description": "Internal op-api upstream for /api/* requests.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "CADDYFILE",
      "service": "op-proxy",
      "description": "Caddy config written to disk at start; routes and client IP headers.",
      "secret": false,
      "strategy": "default",
      "default": ":{$PORT} {\n\thandle_path /api/* {\n\t\treverse_proxy {$API_URL} {\n\t\t\theader_up openpanel-client-ip {http.request.header.X-Real-Ip}\n\t\t\theader_up x-client-ip {http.request.header.X-Real-Ip}\n\t\t}\n\t}\n\treverse_proxy {$DASHBOARD_URL}\n}"
    },
    {
      "key": "DASHBOARD_URL",
      "service": "op-proxy",
      "description": "Internal op-dashboard upstream for all other requests.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "PORT",
      "service": "op-dashboard",
      "description": "HTTP port for this service (3000).",
      "secret": false,
      "strategy": "default",
      "default": "3000"
    },
    {
      "key": "API_URL",
      "service": "op-dashboard",
      "description": "Public API URL: op-proxy domain plus /api.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "REDIS_URL",
      "service": "op-dashboard",
      "description": "Redis URL with password on op-redis private domain.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "API_URL_SSR",
      "service": "op-dashboard",
      "description": "Private API URL the dashboard uses server-side.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "SELF_HOSTED",
      "service": "op-dashboard",
      "description": "Enables self-hosted mode (true).",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "DATABASE_URL",
      "service": "op-dashboard",
      "description": "Postgres connection string from op-postgres.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "COOKIE_SECRET",
      "service": "op-dashboard",
      "description": "Signs session cookies; generated on op-api and shared.",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "DASHBOARD_URL",
      "service": "op-dashboard",
      "description": "Public dashboard URL on the op-proxy domain.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "CLICKHOUSE_URL",
      "service": "op-dashboard",
      "description": "ClickHouse HTTP URL for the openpanel database.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "ALLOW_INVITATION",
      "service": "op-dashboard",
      "description": "Allow inviting teammates by email.",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "ALLOW_REGISTRATION",
      "service": "op-dashboard",
      "description": "Allow sign-up; closes after the first user.",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "DATABASE_URL_DIRECT",
      "service": "op-dashboard",
      "description": "Direct Postgres URL used for migrations.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "CUSTOM_COOKIE_DOMAIN",
      "service": "op-dashboard",
      "description": "Cookie domain; the op-proxy public domain.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "HOST",
      "service": "op-clickhouse",
      "description": "Private hostname of the ClickHouse service.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "PORT",
      "service": "op-clickhouse",
      "description": "ClickHouse HTTP port (8123).",
      "secret": false,
      "strategy": "default",
      "default": "8123"
    },
    {
      "key": "DATABASE_URL",
      "service": "op-clickhouse",
      "description": "HTTP connection URL used by the apps as CLICKHOUSE_URL.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "CLICKHOUSE_DB",
      "service": "op-clickhouse",
      "description": "Database for events (openpanel).",
      "secret": false,
      "strategy": "default",
      "default": "openpanel"
    },
    {
      "key": "CLICKHOUSE_USER",
      "service": "op-clickhouse",
      "description": "ClickHouse user (clickhouse).",
      "secret": false,
      "strategy": "default",
      "default": "clickhouse"
    },
    {
      "key": "DATABASE_BASE_URL",
      "service": "op-clickhouse",
      "description": "ClickHouse HTTP base URL with credentials, without the database name.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "CLICKHOUSE_PASSWORD",
      "service": "op-clickhouse",
      "description": "ClickHouse password, generated per deploy.",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "CLICKHOUSE_DEFAULT_ACCESS_MANAGEMENT",
      "service": "op-clickhouse",
      "description": "Enables SQL-driven access management for the default ClickHouse user (1).",
      "secret": false,
      "strategy": "default",
      "default": "1"
    },
    {
      "key": "PORT",
      "service": "op-redis",
      "description": "Redis port (6379).",
      "secret": false,
      "strategy": "default",
      "default": "6379"
    },
    {
      "key": "REDISHOST",
      "service": "op-redis",
      "description": "Private hostname of the Redis service.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "REDISPORT",
      "service": "op-redis",
      "description": "Redis port (6379).",
      "secret": false,
      "strategy": "default",
      "default": "6379"
    },
    {
      "key": "REDISUSER",
      "service": "op-redis",
      "description": "Redis username (default).",
      "secret": false,
      "strategy": "default",
      "default": "default"
    },
    {
      "key": "REDIS_URL",
      "service": "op-redis",
      "description": "Exported Redis connection URL.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "REDISPASSWORD",
      "service": "op-redis",
      "description": "Redis password; references REDIS_PASSWORD.",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "REDIS_PASSWORD",
      "service": "op-redis",
      "description": "Redis password, generated per deploy.",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "PORT",
      "service": "op-api",
      "description": "HTTP port for this service (3000).",
      "secret": false,
      "strategy": "default",
      "default": "3000"
    },
    {
      "key": "API_URL",
      "service": "op-api",
      "description": "Public API URL: op-proxy domain plus /api.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "API_HOST",
      "service": "op-api",
      "description": "Listen on :: so Railway IPv6 private networking works.",
      "secret": false,
      "strategy": "default",
      "default": "::"
    },
    {
      "key": "REDIS_URL",
      "service": "op-api",
      "description": "Redis URL with password on op-redis private domain.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "SELF_HOSTED",
      "service": "op-api",
      "description": "Enables self-hosted mode (true).",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "DATABASE_URL",
      "service": "op-api",
      "description": "Postgres connection string from op-postgres.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "COOKIE_SECRET",
      "service": "op-api",
      "description": "Signs session cookies; generated on op-api and shared.",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "DASHBOARD_URL",
      "service": "op-api",
      "description": "Public dashboard URL on the op-proxy domain.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "CLICKHOUSE_URL",
      "service": "op-api",
      "description": "ClickHouse HTTP URL for the openpanel database.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "ALLOW_INVITATION",
      "service": "op-api",
      "description": "Allow inviting teammates by email.",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "ALLOW_REGISTRATION",
      "service": "op-api",
      "description": "Allow sign-up; closes after the first user.",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "DATABASE_URL_DIRECT",
      "service": "op-api",
      "description": "Direct Postgres URL used for migrations.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "CUSTOM_COOKIE_DOMAIN",
      "service": "op-api",
      "description": "Cookie domain; the op-proxy public domain.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "deploy-openpanel-vs-plausible"
      }
    },
    "cli": "railway deploy --template deploy-openpanel-vs-plausible",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "43289339-a7e5-454a-af6c-b81643e08a54",
            "serializedConfig": {
              "services": {
                "1a14677d-5b67-4a67-a93b-7a225b9e1657": {
                  "icon": null,
                  "name": "op-worker",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": "/healthcheck",
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "lindesvard/openpanel-worker:2.3.0@sha256:b22e247fb6980b820c1a954d0e3d2fe88b3edf40a58aa53329467af239538e80"
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "HTTP port for this service (3000).",
                      "defaultValue": "3000"
                    },
                    "API_URL": {
                      "isOptional": false,
                      "description": "Public API URL: op-proxy domain plus /api.",
                      "defaultValue": "https://${{op-proxy.RAILWAY_PUBLIC_DOMAIN}}/api"
                    },
                    "API_HOST": {
                      "isOptional": false,
                      "description": "Listen on :: so Railway IPv6 private networking works.",
                      "defaultValue": "::"
                    },
                    "REDIS_URL": {
                      "isOptional": false,
                      "description": "Redis URL with password on op-redis private domain.",
                      "defaultValue": "redis://:${{op-redis.REDIS_PASSWORD}}@${{op-redis.RAILWAY_PRIVATE_DOMAIN}}:6379"
                    },
                    "SELF_HOSTED": {
                      "isOptional": false,
                      "description": "Enables self-hosted mode (true).",
                      "defaultValue": "true"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "Postgres connection string from op-postgres.",
                      "defaultValue": "postgresql://${{op-postgres.POSTGRES_USER}}:${{op-postgres.POSTGRES_PASSWORD}}@${{op-postgres.RAILWAY_PRIVATE_DOMAIN}}:5432/${{op-postgres.POSTGRES_DB}}"
                    },
                    "EMAIL_SENDER": {
                      "isOptional": true,
                      "description": "Optional From address for outgoing emails.",
                      "defaultValue": ""
                    },
                    "COOKIE_SECRET": {
                      "isOptional": false,
                      "description": "Signs session cookies; generated on op-api and shared.",
                      "defaultValue": "${{op-api.COOKIE_SECRET}}"
                    },
                    "DASHBOARD_URL": {
                      "isOptional": false,
                      "description": "Public dashboard URL on the op-proxy domain.",
                      "defaultValue": "https://${{op-proxy.RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "CLICKHOUSE_URL": {
                      "isOptional": false,
                      "description": "ClickHouse HTTP URL for the openpanel database.",
                      "defaultValue": "http://${{op-clickhouse.CLICKHOUSE_USER}}:${{op-clickhouse.CLICKHOUSE_PASSWORD}}@${{op-clickhouse.RAILWAY_PRIVATE_DOMAIN}}:8123/${{op-clickhouse.CLICKHOUSE_DB}}"
                    },
                    "OPENAI_API_KEY": {
                      "isOptional": true,
                      "description": "Optional OpenAI key for in-app AI chat.",
                      "defaultValue": ""
                    },
                    "RESEND_API_KEY": {
                      "isOptional": true,
                      "description": "Optional Resend key for invite and reset emails.",
                      "defaultValue": ""
                    },
                    "ALLOW_INVITATION": {
                      "isOptional": false,
                      "description": "Allow inviting teammates by email.",
                      "defaultValue": "true"
                    },
                    "ANTHROPIC_API_KEY": {
                      "isOptional": true,
                      "description": "Optional Anthropic key for in-app AI chat.",
                      "defaultValue": ""
                    },
                    "ALLOW_REGISTRATION": {
                      "isOptional": false,
                      "description": "Allow sign-up; closes after the first user.",
                      "defaultValue": "true"
                    },
                    "DATABASE_URL_DIRECT": {
                      "isOptional": false,
                      "description": "Direct Postgres URL used for migrations.",
                      "defaultValue": "postgresql://${{op-postgres.POSTGRES_USER}}:${{op-postgres.POSTGRES_PASSWORD}}@${{op-postgres.RAILWAY_PRIVATE_DOMAIN}}:5432/${{op-postgres.POSTGRES_DB}}"
                    }
                  }
                },
                "21dcd18e-c299-4156-b8e7-3757fcc2301f": {
                  "icon": null,
                  "name": "op-postgres",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": null,
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "ghcr.io/railwayapp-templates/postgres-ssl:17"
                  },
                  "variables": {
                    "PGDATA": {
                      "isOptional": false,
                      "description": "Data directory inside the volume.",
                      "defaultValue": "/var/lib/postgresql/data/pgdata"
                    },
                    "PGHOST": {
                      "isOptional": false,
                      "description": "Private hostname of the Postgres service.",
                      "defaultValue": "${{RAILWAY_PRIVATE_DOMAIN}}"
                    },
                    "PGPORT": {
                      "isOptional": false,
                      "description": "Postgres port (5432).",
                      "defaultValue": "5432"
                    },
                    "PGUSER": {
                      "isOptional": false,
                      "description": "Postgres username used by clients; references POSTGRES_USER.",
                      "defaultValue": "${{POSTGRES_USER}}"
                    },
                    "PGDATABASE": {
                      "isOptional": false,
                      "description": "Postgres database name; references POSTGRES_DB.",
                      "defaultValue": "${{POSTGRES_DB}}"
                    },
                    "PGPASSWORD": {
                      "isOptional": false,
                      "description": "Postgres password; references POSTGRES_PASSWORD.",
                      "defaultValue": "${{POSTGRES_PASSWORD}}"
                    },
                    "POSTGRES_DB": {
                      "isOptional": false,
                      "description": "Database created on first boot (railway).",
                      "defaultValue": "railway"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "Private connection string used by the apps.",
                      "defaultValue": "postgresql://${{POSTGRES_USER}}:${{POSTGRES_PASSWORD}}@${{RAILWAY_PRIVATE_DOMAIN}}:5432/${{POSTGRES_DB}}"
                    },
                    "POSTGRES_USER": {
                      "isOptional": false,
                      "description": "Postgres superuser (postgres).",
                      "defaultValue": "postgres"
                    },
                    "SSL_CERT_DAYS": {
                      "isOptional": false,
                      "description": "Validity in days of the self-signed SSL certificate.",
                      "defaultValue": "820"
                    },
                    "POSTGRES_PASSWORD": {
                      "isOptional": false,
                      "description": "Postgres password, generated per deploy.",
                      "defaultValue": "{{POSTGRES_PASSWORD}}"
                    }
                  },
                  "volumeMounts": {
                    "21dcd18e-c299-4156-b8e7-3757fcc2301f": {
                      "mountPath": "/var/lib/postgresql/data"
                    }
                  }
                },
                "841937bf-c2ec-4b45-b35d-50b63ca20bee": {
                  "icon": null,
                  "name": "op-proxy",
                  "deploy": {
                    "startCommand": "sh -c \"echo \\\"$CADDYFILE\\\" > /etc/caddy/Caddyfile; echo START_OK PORT=$PORT; cat /etc/caddy/Caddyfile; exec caddy run --config /etc/caddy/Caddyfile --adapter caddyfile\"",
                    "healthcheckPath": null,
                    "restartPolicyType": "ALWAYS",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "caddy:2-alpine@sha256:d8542f48d34a9cf4e4c11a478865229840e87e4c96ea3f439101f31a5d35f75f"
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "Caddy listen port and public target port (8080).",
                      "defaultValue": "8080"
                    },
                    "API_URL": {
                      "isOptional": false,
                      "description": "Internal op-api upstream for /api/* requests.",
                      "defaultValue": "http://${{op-api.RAILWAY_PRIVATE_DOMAIN}}:${{op-api.PORT}}"
                    },
                    "CADDYFILE": {
                      "isOptional": false,
                      "description": "Caddy config written to disk at start; routes and client IP headers.",
                      "defaultValue": ":{$PORT} {\n\thandle_path /api/* {\n\t\treverse_proxy {$API_URL} {\n\t\t\theader_up openpanel-client-ip {http.request.header.X-Real-Ip}\n\t\t\theader_up x-client-ip {http.request.header.X-Real-Ip}\n\t\t}\n\t}\n\treverse_proxy {$DASHBOARD_URL}\n}"
                    },
                    "DASHBOARD_URL": {
                      "isOptional": false,
                      "description": "Internal op-dashboard upstream for all other requests.",
                      "defaultValue": "http://${{op-dashboard.RAILWAY_PRIVATE_DOMAIN}}:${{op-dashboard.PORT}}"
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>:8080": {
                        "port": 8080
                      }
                    }
                  }
                },
                "866b380c-0b6b-4ccf-ba6b-c7d93924dc7c": {
                  "icon": null,
                  "name": "op-dashboard",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": "/api/healthcheck",
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "lindesvard/openpanel-dashboard:2.3.0@sha256:b773cf864454a0ec89b2a133b48bf06202880ed650a75cc2f1f5c87aaed1cffa"
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "HTTP port for this service (3000).",
                      "defaultValue": "3000"
                    },
                    "API_URL": {
                      "isOptional": false,
                      "description": "Public API URL: op-proxy domain plus /api.",
                      "defaultValue": "https://${{op-proxy.RAILWAY_PUBLIC_DOMAIN}}/api"
                    },
                    "REDIS_URL": {
                      "isOptional": false,
                      "description": "Redis URL with password on op-redis private domain.",
                      "defaultValue": "redis://:${{op-redis.REDIS_PASSWORD}}@${{op-redis.RAILWAY_PRIVATE_DOMAIN}}:6379"
                    },
                    "API_URL_SSR": {
                      "isOptional": false,
                      "description": "Private API URL the dashboard uses server-side.",
                      "defaultValue": "http://${{op-api.RAILWAY_PRIVATE_DOMAIN}}:${{op-api.PORT}}"
                    },
                    "SELF_HOSTED": {
                      "isOptional": false,
                      "description": "Enables self-hosted mode (true).",
                      "defaultValue": "true"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "Postgres connection string from op-postgres.",
                      "defaultValue": "postgresql://${{op-postgres.POSTGRES_USER}}:${{op-postgres.POSTGRES_PASSWORD}}@${{op-postgres.RAILWAY_PRIVATE_DOMAIN}}:5432/${{op-postgres.POSTGRES_DB}}"
                    },
                    "COOKIE_SECRET": {
                      "isOptional": false,
                      "description": "Signs session cookies; generated on op-api and shared.",
                      "defaultValue": "${{op-api.COOKIE_SECRET}}"
                    },
                    "DASHBOARD_URL": {
                      "isOptional": false,
                      "description": "Public dashboard URL on the op-proxy domain.",
                      "defaultValue": "https://${{op-proxy.RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "CLICKHOUSE_URL": {
                      "isOptional": false,
                      "description": "ClickHouse HTTP URL for the openpanel database.",
                      "defaultValue": "http://${{op-clickhouse.CLICKHOUSE_USER}}:${{op-clickhouse.CLICKHOUSE_PASSWORD}}@${{op-clickhouse.RAILWAY_PRIVATE_DOMAIN}}:8123/${{op-clickhouse.CLICKHOUSE_DB}}"
                    },
                    "ALLOW_INVITATION": {
                      "isOptional": false,
                      "description": "Allow inviting teammates by email.",
                      "defaultValue": "true"
                    },
                    "ALLOW_REGISTRATION": {
                      "isOptional": false,
                      "description": "Allow sign-up; closes after the first user.",
                      "defaultValue": "true"
                    },
                    "DATABASE_URL_DIRECT": {
                      "isOptional": false,
                      "description": "Direct Postgres URL used for migrations.",
                      "defaultValue": "postgresql://${{op-postgres.POSTGRES_USER}}:${{op-postgres.POSTGRES_PASSWORD}}@${{op-postgres.RAILWAY_PRIVATE_DOMAIN}}:5432/${{op-postgres.POSTGRES_DB}}"
                    },
                    "CUSTOM_COOKIE_DOMAIN": {
                      "isOptional": false,
                      "description": "Cookie domain; the op-proxy public domain.",
                      "defaultValue": "${{op-proxy.RAILWAY_PUBLIC_DOMAIN}}"
                    }
                  }
                },
                "ae2a0d2f-2434-4eb5-ab55-77c5f4735e2b": {
                  "icon": null,
                  "name": "op-clickhouse",
                  "deploy": {
                    "startCommand": "sh -c 'mkdir -p /etc/clickhouse-server/config.d && printf \"%s\\n\" \"<clickhouse><listen_host>::</listen_host><listen_host>0.0.0.0</listen_host><trace_log remove=\\\"remove\\\"/><text_log remove=\\\"remove\\\"/><metric_log remove=\\\"remove\\\"/><asynchronous_metric_log remove=\\\"remove\\\"/><processors_profile_log remove=\\\"remove\\\"/><query_metric_log remove=\\\"remove\\\"/><query_thread_log remove=\\\"remove\\\"/><query_views_log remove=\\\"remove\\\"/><asynchronous_insert_log remove=\\\"remove\\\"/><opentelemetry_span_log remove=\\\"remove\\\"/><background_schedule_pool_log remove=\\\"remove\\\"/></clickhouse>\" > /etc/clickhouse-server/config.d/railway-listen.xml && exec /entrypoint.sh'",
                    "healthcheckPath": null,
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "clickhouse/clickhouse-server:25.12@sha256:8a790dd3468db22b1d4e7b18a176f378ff5ff6053b9c48dd4ea1fa71a24c5ba6"
                  },
                  "variables": {
                    "HOST": {
                      "isOptional": false,
                      "description": "Private hostname of the ClickHouse service.",
                      "defaultValue": "${{RAILWAY_PRIVATE_DOMAIN}}"
                    },
                    "PORT": {
                      "isOptional": false,
                      "description": "ClickHouse HTTP port (8123).",
                      "defaultValue": "8123"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "HTTP connection URL used by the apps as CLICKHOUSE_URL.",
                      "defaultValue": "http://${{CLICKHOUSE_USER}}:${{CLICKHOUSE_PASSWORD}}@${{RAILWAY_PRIVATE_DOMAIN}}:${{PORT}}/${{CLICKHOUSE_DB}}"
                    },
                    "CLICKHOUSE_DB": {
                      "isOptional": false,
                      "description": "Database for events (openpanel).",
                      "defaultValue": "openpanel"
                    },
                    "CLICKHOUSE_USER": {
                      "isOptional": false,
                      "description": "ClickHouse user (clickhouse).",
                      "defaultValue": "clickhouse"
                    },
                    "DATABASE_BASE_URL": {
                      "isOptional": false,
                      "description": "ClickHouse HTTP base URL with credentials, without the database name.",
                      "defaultValue": "http://${{CLICKHOUSE_USER}}:${{CLICKHOUSE_PASSWORD}}@${{RAILWAY_PRIVATE_DOMAIN}}:${{PORT}}"
                    },
                    "CLICKHOUSE_PASSWORD": {
                      "isOptional": false,
                      "description": "ClickHouse password, generated per deploy.",
                      "defaultValue": "{{CLICKHOUSE_PASSWORD}}"
                    },
                    "CLICKHOUSE_DEFAULT_ACCESS_MANAGEMENT": {
                      "isOptional": false,
                      "description": "Enables SQL-driven access management for the default ClickHouse user (1).",
                      "defaultValue": "1"
                    }
                  },
                  "volumeMounts": {
                    "ae2a0d2f-2434-4eb5-ab55-77c5f4735e2b": {
                      "mountPath": "/var/lib/clickhouse"
                    }
                  }
                },
                "b3366821-9de2-4688-8395-26776982a056": {
                  "icon": null,
                  "name": "op-redis",
                  "deploy": {
                    "startCommand": "/bin/sh -c \"rm -rf ${RAILWAY_VOLUME_MOUNT_PATH}/lost+found/ && exec docker-entrypoint.sh redis-server --requirepass ${REDIS_PASSWORD} --bind '* -::*' --protected-mode no --port ${PORT:-6379} --save 60 1 --dir ${RAILWAY_VOLUME_MOUNT_PATH}\"",
                    "healthcheckPath": null,
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "redis:8.2.1@sha256:5fa2edb1e408fa8235e6db8fab01d1afaaae96c9403ba67b70feceb8661e8621"
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "Redis port (6379).",
                      "defaultValue": "6379"
                    },
                    "REDISHOST": {
                      "isOptional": false,
                      "description": "Private hostname of the Redis service.",
                      "defaultValue": "${{RAILWAY_PRIVATE_DOMAIN}}"
                    },
                    "REDISPORT": {
                      "isOptional": false,
                      "description": "Redis port (6379).",
                      "defaultValue": "6379"
                    },
                    "REDISUSER": {
                      "isOptional": false,
                      "description": "Redis username (default).",
                      "defaultValue": "default"
                    },
                    "REDIS_URL": {
                      "isOptional": false,
                      "description": "Exported Redis connection URL.",
                      "defaultValue": "redis://${{REDISUSER}}:${{REDIS_PASSWORD}}@${{REDISHOST}}:${{REDISPORT}}"
                    },
                    "REDISPASSWORD": {
                      "isOptional": false,
                      "description": "Redis password; references REDIS_PASSWORD.",
                      "defaultValue": "${{REDIS_PASSWORD}}"
                    },
                    "REDIS_PASSWORD": {
                      "isOptional": false,
                      "description": "Redis password, generated per deploy.",
                      "defaultValue": "{{REDIS_PASSWORD}}"
                    }
                  },
                  "volumeMounts": {
                    "b3366821-9de2-4688-8395-26776982a056": {
                      "mountPath": "/data"
                    }
                  }
                },
                "d9e6da8e-09ae-4fb5-9354-6307f2fb39e4": {
                  "icon": null,
                  "name": "op-api",
                  "deploy": {
                    "startCommand": "sh -c \"echo Running migrations...; CI=true pnpm -r run migrate:deploy; exec pnpm start\"",
                    "healthcheckPath": "/healthcheck",
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "lindesvard/openpanel-api:2.3.0@sha256:cee4855cd715a7248c5c49090fe93a28ffc505541de20cb238d8884a6bcb9223"
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "HTTP port for this service (3000).",
                      "defaultValue": "3000"
                    },
                    "API_URL": {
                      "isOptional": false,
                      "description": "Public API URL: op-proxy domain plus /api.",
                      "defaultValue": "https://${{op-proxy.RAILWAY_PUBLIC_DOMAIN}}/api"
                    },
                    "API_HOST": {
                      "isOptional": false,
                      "description": "Listen on :: so Railway IPv6 private networking works.",
                      "defaultValue": "::"
                    },
                    "REDIS_URL": {
                      "isOptional": false,
                      "description": "Redis URL with password on op-redis private domain.",
                      "defaultValue": "redis://:${{op-redis.REDIS_PASSWORD}}@${{op-redis.RAILWAY_PRIVATE_DOMAIN}}:6379"
                    },
                    "SELF_HOSTED": {
                      "isOptional": false,
                      "description": "Enables self-hosted mode (true).",
                      "defaultValue": "true"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "Postgres connection string from op-postgres.",
                      "defaultValue": "postgresql://${{op-postgres.POSTGRES_USER}}:${{op-postgres.POSTGRES_PASSWORD}}@${{op-postgres.RAILWAY_PRIVATE_DOMAIN}}:5432/${{op-postgres.POSTGRES_DB}}"
                    },
                    "EMAIL_SENDER": {
                      "isOptional": true,
                      "description": "Optional From address for outgoing emails.",
                      "defaultValue": ""
                    },
                    "COOKIE_SECRET": {
                      "isOptional": false,
                      "description": "Signs session cookies; generated on op-api and shared.",
                      "defaultValue": "{{COOKIE_SECRET}}"
                    },
                    "DASHBOARD_URL": {
                      "isOptional": false,
                      "description": "Public dashboard URL on the op-proxy domain.",
                      "defaultValue": "https://${{op-proxy.RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "CLICKHOUSE_URL": {
                      "isOptional": false,
                      "description": "ClickHouse HTTP URL for the openpanel database.",
                      "defaultValue": "http://${{op-clickhouse.CLICKHOUSE_USER}}:${{op-clickhouse.CLICKHOUSE_PASSWORD}}@${{op-clickhouse.RAILWAY_PRIVATE_DOMAIN}}:8123/${{op-clickhouse.CLICKHOUSE_DB}}"
                    },
                    "OPENAI_API_KEY": {
                      "isOptional": true,
                      "description": "Optional OpenAI key for in-app AI chat.",
                      "defaultValue": ""
                    },
                    "RESEND_API_KEY": {
                      "isOptional": true,
                      "description": "Optional Resend key for invite and reset emails.",
                      "defaultValue": ""
                    },
                    "ALLOW_INVITATION": {
                      "isOptional": false,
                      "description": "Allow inviting teammates by email.",
                      "defaultValue": "true"
                    },
                    "ANTHROPIC_API_KEY": {
                      "isOptional": true,
                      "description": "Optional Anthropic key for in-app AI chat.",
                      "defaultValue": ""
                    },
                    "ALLOW_REGISTRATION": {
                      "isOptional": false,
                      "description": "Allow sign-up; closes after the first user.",
                      "defaultValue": "true"
                    },
                    "DATABASE_URL_DIRECT": {
                      "isOptional": false,
                      "description": "Direct Postgres URL used for migrations.",
                      "defaultValue": "postgresql://${{op-postgres.POSTGRES_USER}}:${{op-postgres.POSTGRES_PASSWORD}}@${{op-postgres.RAILWAY_PRIVATE_DOMAIN}}:5432/${{op-postgres.POSTGRES_DB}}"
                    },
                    "CUSTOM_COOKIE_DOMAIN": {
                      "isOptional": false,
                      "description": "Cookie domain; the op-proxy public domain.",
                      "defaultValue": "${{op-proxy.RAILWAY_PUBLIC_DOMAIN}}"
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {},
  "resources": {
    "expected_services": 7,
    "needs_volume": true
  },
  "generated_at": "2026-10-17T04:14:47.046Z",
  "generator_version": "0.1.0",
  "status": "validated",
  "validated_at": "2026-10-17T02:37:22.917Z",
  "success_rate_30d": 1,
  "validation": {
    "last_run_id": "run_719b201cb57d47e0856f",
    "checks": [
      {
        "name": "workflow_completed",
        "passed": true
      },
      {
        "name": "all_services_deployed",
        "passed": true
      },
      {
        "name": "stays_up",
        "passed": true
      }
    ],
    "typical_ready_seconds": 129,
    "typical_build_seconds": 0,
    "typical_start_seconds": 10,
    "slowest_service": "op-worker"
  }
}
