{
  "manifest_version": "1.0.0",
  "template": {
    "id": "95803b70-4881-4b79-ae5c-1d5df8aa804a",
    "slug": "lightpanda-1",
    "name": "lightpanda",
    "description": "Lightpanda 0.4: fast headless browser for agents over CDP, token-gated.",
    "url": "https://railway.com/deploy/lightpanda-1",
    "upstream": {
      "image": "caddy:2.11.4-alpine"
    }
  },
  "services": [
    {
      "name": "lightpanda",
      "source": {
        "image": "lightpanda/browser:0.4.1"
      },
      "needs_volume": false,
      "http": false
    },
    {
      "name": "gateway",
      "source": {
        "image": "caddy:2.11.4-alpine"
      },
      "needs_volume": false,
      "http": true
    }
  ],
  "required_inputs": [
    {
      "key": "PORT",
      "service": "lightpanda",
      "description": "Provide a value for PORT.",
      "secret": false,
      "strategy": "default",
      "default": "9222"
    },
    {
      "key": "LIGHTPANDA_DISABLE_TELEMETRY",
      "service": "lightpanda",
      "description": "Provide a value for LIGHTPANDA_DISABLE_TELEMETRY.",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "PORT",
      "service": "gateway",
      "description": "Provide a value for PORT.",
      "secret": false,
      "strategy": "default",
      "default": "8080"
    },
    {
      "key": "CADDYFILE",
      "service": "gateway",
      "description": "Provide a value for CADDYFILE.",
      "secret": false,
      "strategy": "default",
      "default": "{\n\tadmin off\n\tauto_https off\n}\n\n:{$PORT} {\n\thandle /gateway_health {\n\t\trespond ok 200\n\t}\n\n\t@authorized {\n\t\theader Authorization `Bearer {$LIGHTPANDA_TOKEN}`\n\t}\n\t@authorized_query {\n\t\tquery token={$LIGHTPANDA_TOKEN}\n\t}\n\t# Lightpanda only accepts WebSocket connections addressed to its own host.\n\thandle @authorized {\n\t\treverse_proxy {$LIGHTPANDA_UPSTREAM} {\n\t\t\theader_up Host 127.0.0.1:9222\n\t\t}\n\t}\n\thandle @authorized_query {\n\t\treverse_proxy {$LIGHTPANDA_UPSTREAM} {\n\t\t\theader_up Host 127.0.0.1:9222\n\t\t}\n\t}\n\n\thandle {\n\t\trespond Unauthorized 401\n\t}\n}"
    },
    {
      "key": "LIGHTPANDA_TOKEN",
      "service": "gateway",
      "description": "Provide a value for LIGHTPANDA_TOKEN.",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "LIGHTPANDA_WS_URL",
      "service": "gateway",
      "description": "Provide a value for LIGHTPANDA_WS_URL.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "LIGHTPANDA_UPSTREAM",
      "service": "gateway",
      "description": "Provide a value for LIGHTPANDA_UPSTREAM.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "lightpanda-1"
      }
    },
    "cli": "railway deploy --template lightpanda-1",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "95803b70-4881-4b79-ae5c-1d5df8aa804a",
            "serializedConfig": {
              "buckets": {},
              "services": {
                "c8de0d43-8df1-4c49-a2f7-4d8df909387d": {
                  "icon": "https://cdn.lightpanda.io/assets/images/logo/lpd-logo.png",
                  "name": "lightpanda",
                  "deploy": {
                    "startCommand": "/usr/bin/tini -- /bin/lightpanda serve --host :: --port 9222 --log_level info",
                    "healthcheckPath": null,
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "lightpanda/browser:0.4.1"
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "defaultValue": "9222"
                    },
                    "LIGHTPANDA_DISABLE_TELEMETRY": {
                      "isOptional": false,
                      "defaultValue": "true"
                    }
                  }
                },
                "e7844bef-aefb-4ff0-9070-d74f5668c827": {
                  "icon": "https://raw.githubusercontent.com/caddyserver/website/5c921006aae4feb2184782ae528c2bb09a07e04f/src/resources/images/favicon.png",
                  "name": "gateway",
                  "deploy": {
                    "startCommand": "sh -c 'printf \"%s\\n\" \"$CADDYFILE\" > /tmp/Caddyfile && exec caddy run --config /tmp/Caddyfile --adapter caddyfile'",
                    "healthcheckPath": "/gateway_health",
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "caddy:2.11.4-alpine"
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "defaultValue": "8080"
                    },
                    "CADDYFILE": {
                      "isOptional": false,
                      "defaultValue": "{\n\tadmin off\n\tauto_https off\n}\n\n:{$PORT} {\n\thandle /gateway_health {\n\t\trespond ok 200\n\t}\n\n\t@authorized {\n\t\theader Authorization `Bearer {$LIGHTPANDA_TOKEN}`\n\t}\n\t@authorized_query {\n\t\tquery token={$LIGHTPANDA_TOKEN}\n\t}\n\t# Lightpanda only accepts WebSocket connections addressed to its own host.\n\thandle @authorized {\n\t\treverse_proxy {$LIGHTPANDA_UPSTREAM} {\n\t\t\theader_up Host 127.0.0.1:9222\n\t\t}\n\t}\n\thandle @authorized_query {\n\t\treverse_proxy {$LIGHTPANDA_UPSTREAM} {\n\t\t\theader_up Host 127.0.0.1:9222\n\t\t}\n\t}\n\n\thandle {\n\t\trespond Unauthorized 401\n\t}\n}"
                    },
                    "LIGHTPANDA_TOKEN": {
                      "isOptional": false,
                      "defaultValue": "{{LIGHTPANDA_TOKEN}}"
                    },
                    "LIGHTPANDA_WS_URL": {
                      "isOptional": false,
                      "defaultValue": "wss://${{RAILWAY_PUBLIC_DOMAIN}}/?token=${{LIGHTPANDA_TOKEN}}"
                    },
                    "LIGHTPANDA_UPSTREAM": {
                      "isOptional": false,
                      "defaultValue": "${{lightpanda.RAILWAY_PRIVATE_DOMAIN}}:9222"
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>:8080": {
                        "port": 8080
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {
    "healthcheck": {
      "service": "gateway",
      "method": "GET",
      "path": "/gateway_health",
      "expect_status": 200
    }
  },
  "resources": {
    "expected_services": 2,
    "needs_volume": false
  },
  "generated_at": "2026-09-24T22:14:48.880Z",
  "generator_version": "0.1.0",
  "status": "validated",
  "validated_at": "2026-09-24T19:41:45.205Z",
  "success_rate_30d": 1,
  "validation": {
    "last_run_id": "run_9f6a063fcd1647e8b1f9",
    "checks": [
      {
        "name": "workflow_completed",
        "passed": true
      },
      {
        "name": "all_services_deployed",
        "passed": true
      },
      {
        "name": "healthcheck",
        "passed": true
      },
      {
        "name": "stays_up",
        "passed": true
      }
    ],
    "typical_ready_seconds": 39,
    "typical_build_seconds": 0,
    "typical_start_seconds": 0,
    "slowest_service": "lightpanda"
  }
}
