{
  "manifest_version": "1.0.0",
  "template": {
    "id": "1875a9ef-fbda-41e6-b01b-5863bb3e75eb",
    "slug": "centrifugo",
    "name": "Centrifugo",
    "description": "Real-time messaging server that pushes messages to connected users",
    "url": "https://railway.com/deploy/centrifugo",
    "upstream": {
      "image": "centrifugo/centrifugo:v6"
    }
  },
  "services": [
    {
      "name": "centrifugo",
      "source": {
        "image": "centrifugo/centrifugo:v6"
      },
      "needs_volume": false,
      "http": true
    },
    {
      "name": "Redis",
      "source": {
        "image": "redis:8.2"
      },
      "needs_volume": true,
      "volume_mount_path": "/data",
      "http": false
    }
  ],
  "required_inputs": [
    {
      "key": "PORT",
      "service": "centrifugo",
      "description": "Port Railway health-probes",
      "secret": false,
      "strategy": "default",
      "default": "8000"
    },
    {
      "key": "CENTRIFUGO_ENGINE_TYPE",
      "service": "centrifugo",
      "description": "Broker and presence backend",
      "secret": false,
      "strategy": "default",
      "default": "redis"
    },
    {
      "key": "CENTRIFUGO_SSE_ENABLED",
      "service": "centrifugo",
      "description": "Server-Sent Events fallback transport",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "CENTRIFUGO_ADMIN_SECRET",
      "service": "centrifugo",
      "description": "Signs admin session tokens",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "CENTRIFUGO_HTTP_API_KEY",
      "service": "centrifugo",
      "description": "Server API key for /api requests",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "CENTRIFUGO_ADMIN_ENABLED",
      "service": "centrifugo",
      "description": "Serve the admin web UI",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "CENTRIFUGO_ADMIN_PASSWORD",
      "service": "centrifugo",
      "description": "Admin web UI sign-in password",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "CENTRIFUGO_HEALTH_ENABLED",
      "service": "centrifugo",
      "description": "Enables the /health endpoint",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "CENTRIFUGO_HTTP_SERVER_PORT",
      "service": "centrifugo",
      "description": "HTTP listen port",
      "secret": false,
      "strategy": "default",
      "default": "8000"
    },
    {
      "key": "CENTRIFUGO_HTTP_STREAM_ENABLED",
      "service": "centrifugo",
      "description": "HTTP-streaming fallback transport",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "CENTRIFUGO_ENGINE_REDIS_ADDRESS",
      "service": "centrifugo",
      "description": "Redis engine connection string",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "CENTRIFUGO_CLIENT_ALLOWED_ORIGINS",
      "service": "centrifugo",
      "description": "Space-separated allowed browser origins",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "RAILWAY_DEPLOYMENT_DRAINING_SECONDS",
      "service": "centrifugo",
      "description": "Clean socket shutdown window",
      "secret": false,
      "strategy": "default",
      "default": "30"
    },
    {
      "key": "CENTRIFUGO_CLIENT_TOKEN_HMAC_SECRET_KEY",
      "service": "centrifugo",
      "description": "HS256 key for client JWTs",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "REDISHOST",
      "service": "Redis",
      "description": "Data panel alias, not read by the server",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "REDISPORT",
      "service": "Redis",
      "description": "Data panel alias, not read by the server",
      "secret": false,
      "strategy": "default",
      "default": "6379"
    },
    {
      "key": "REDISUSER",
      "service": "Redis",
      "description": "Data panel alias, not read by the server",
      "secret": false,
      "strategy": "default",
      "default": "default"
    },
    {
      "key": "REDIS_URL",
      "service": "Redis",
      "description": "Private connection string",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "REDISPASSWORD",
      "service": "Redis",
      "description": "Data panel alias, not read by the server",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "REDIS_PASSWORD",
      "service": "Redis",
      "description": "Auth password, read by the server",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "centrifugo"
      }
    },
    "cli": "railway deploy --template centrifugo",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "1875a9ef-fbda-41e6-b01b-5863bb3e75eb",
            "serializedConfig": {
              "buckets": {},
              "services": {
                "9f94b374-3642-4a20-b289-dab00658ab91": {
                  "icon": "https://centrifugal.dev/img/logo.svg",
                  "name": "centrifugo",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": "/health",
                    "restartPolicyType": "ALWAYS",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "centrifugo/centrifugo:v6"
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "Port Railway health-probes",
                      "defaultValue": "8000"
                    },
                    "CENTRIFUGO_ENGINE_TYPE": {
                      "isOptional": false,
                      "description": "Broker and presence backend",
                      "defaultValue": "redis"
                    },
                    "CENTRIFUGO_SSE_ENABLED": {
                      "isOptional": false,
                      "description": "Server-Sent Events fallback transport",
                      "defaultValue": "true"
                    },
                    "CENTRIFUGO_ADMIN_SECRET": {
                      "isOptional": false,
                      "description": "Signs admin session tokens",
                      "defaultValue": "{{CENTRIFUGO_ADMIN_SECRET}}"
                    },
                    "CENTRIFUGO_HTTP_API_KEY": {
                      "isOptional": false,
                      "description": "Server API key for /api requests",
                      "defaultValue": "{{CENTRIFUGO_HTTP_API_KEY}}"
                    },
                    "CENTRIFUGO_ADMIN_ENABLED": {
                      "isOptional": false,
                      "description": "Serve the admin web UI",
                      "defaultValue": "true"
                    },
                    "CENTRIFUGO_ADMIN_PASSWORD": {
                      "isOptional": false,
                      "description": "Admin web UI sign-in password",
                      "defaultValue": "{{CENTRIFUGO_ADMIN_PASSWORD}}"
                    },
                    "CENTRIFUGO_HEALTH_ENABLED": {
                      "isOptional": false,
                      "description": "Enables the /health endpoint",
                      "defaultValue": "true"
                    },
                    "CENTRIFUGO_HTTP_SERVER_PORT": {
                      "isOptional": false,
                      "description": "HTTP listen port",
                      "defaultValue": "8000"
                    },
                    "CENTRIFUGO_HTTP_STREAM_ENABLED": {
                      "isOptional": false,
                      "description": "HTTP-streaming fallback transport",
                      "defaultValue": "true"
                    },
                    "CENTRIFUGO_ENGINE_REDIS_ADDRESS": {
                      "isOptional": false,
                      "description": "Redis engine connection string",
                      "defaultValue": "${{Redis.REDIS_URL}}"
                    },
                    "CENTRIFUGO_CLIENT_ALLOWED_ORIGINS": {
                      "isOptional": false,
                      "description": "Space-separated allowed browser origins",
                      "defaultValue": "https://${{RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "RAILWAY_DEPLOYMENT_DRAINING_SECONDS": {
                      "isOptional": false,
                      "description": "Clean socket shutdown window",
                      "defaultValue": "30"
                    },
                    "CENTRIFUGO_CLIENT_TOKEN_HMAC_SECRET_KEY": {
                      "isOptional": false,
                      "description": "HS256 key for client JWTs",
                      "defaultValue": "{{CENTRIFUGO_CLIENT_TOKEN_HMAC_SECRET_KEY}}"
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>:8000": {
                        "port": 8000
                      }
                    }
                  }
                },
                "bb2c1806-d2f4-4d5d-bbe6-3843ebda2f65": {
                  "icon": "https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/redis.svg",
                  "name": "Redis",
                  "deploy": {
                    "startCommand": "/bin/sh -c \"rm -rf $RAILWAY_VOLUME_MOUNT_PATH/lost+found/ && exec docker-entrypoint.sh redis-server --requirepass $REDIS_PASSWORD --save 60 1 --dir $RAILWAY_VOLUME_MOUNT_PATH\"",
                    "healthcheckPath": null,
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "redis:8.2"
                  },
                  "variables": {
                    "REDISHOST": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "${{RAILWAY_PRIVATE_DOMAIN}}"
                    },
                    "REDISPORT": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "6379"
                    },
                    "REDISUSER": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "default"
                    },
                    "REDIS_URL": {
                      "isOptional": false,
                      "description": "Private connection string",
                      "defaultValue": "redis://${{REDISUSER}}:${{REDIS_PASSWORD}}@${{REDISHOST}}:${{REDISPORT}}"
                    },
                    "REDISPASSWORD": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "${{REDIS_PASSWORD}}"
                    },
                    "REDIS_PASSWORD": {
                      "isOptional": false,
                      "description": "Auth password, read by the server",
                      "defaultValue": "{{REDIS_PASSWORD}}"
                    }
                  },
                  "volumeMounts": {
                    "bb2c1806-d2f4-4d5d-bbe6-3843ebda2f65": {
                      "mountPath": "/data"
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {
    "healthcheck": {
      "service": "centrifugo",
      "method": "GET",
      "path": "/health",
      "expect_status": 200
    }
  },
  "resources": {
    "expected_services": 2,
    "needs_volume": true
  },
  "generated_at": "2026-09-04T05:44:27.711Z",
  "generator_version": "0.1.0",
  "status": "validated",
  "validated_at": "2026-09-04T05:32:28.074Z",
  "success_rate_30d": 1,
  "validation": {
    "last_run_id": "run_d6274dfd56024636b21c",
    "checks": [
      {
        "name": "workflow_completed",
        "passed": true
      },
      {
        "name": "all_services_deployed",
        "passed": true
      },
      {
        "name": "healthcheck",
        "passed": true
      },
      {
        "name": "stays_up",
        "passed": true
      }
    ],
    "typical_ready_seconds": 98,
    "typical_build_seconds": 0,
    "typical_deploy_seconds": 10,
    "typical_healthcheck_lag_seconds": 0,
    "slowest_service": "centrifugo"
  }
}
