{
  "manifest_version": "1.0.0",
  "template": {
    "id": "7bb65887-51fd-4ad5-baff-e5e8c5955100",
    "slug": "hasura-graphql",
    "name": "Hasura",
    "description": "Turns a Postgres database into a ready-made GraphQL API",
    "url": "https://railway.com/deploy/hasura-graphql",
    "upstream": {
      "image": "hasura/graphql-engine:latest"
    }
  },
  "services": [
    {
      "name": "Postgres",
      "source": {
        "image": "ghcr.io/railwayapp-templates/postgres-ssl:18"
      },
      "needs_volume": true,
      "volume_mount_path": "/var/lib/postgresql/data",
      "http": false
    },
    {
      "name": "hasura",
      "source": {
        "image": "hasura/graphql-engine:latest"
      },
      "needs_volume": false,
      "http": true
    },
    {
      "name": "Postgres-Metadata",
      "source": {
        "image": "ghcr.io/railwayapp-templates/postgres-ssl:18"
      },
      "needs_volume": true,
      "volume_mount_path": "/var/lib/postgresql/data",
      "http": false
    }
  ],
  "required_inputs": [
    {
      "key": "PGDATA",
      "service": "Postgres",
      "description": "Cluster location on the volume",
      "secret": false,
      "strategy": "default",
      "default": "/var/lib/postgresql/data/pgdata"
    },
    {
      "key": "PGHOST",
      "service": "Postgres",
      "description": "Data panel alias, not read by the server",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "PGPORT",
      "service": "Postgres",
      "description": "Data panel alias, not read by the server",
      "secret": false,
      "strategy": "default",
      "default": "5432"
    },
    {
      "key": "PGUSER",
      "service": "Postgres",
      "description": "Data panel alias, not read by the server",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PGDATABASE",
      "service": "Postgres",
      "description": "Data panel alias, not read by the server",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PGPASSWORD",
      "service": "Postgres",
      "description": "Data panel alias, not read by the server",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "POSTGRES_DB",
      "service": "Postgres",
      "description": "Database created on first boot",
      "secret": false,
      "strategy": "default",
      "default": "railway"
    },
    {
      "key": "DATABASE_URL",
      "service": "Postgres",
      "description": "Private connection string",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "POSTGRES_USER",
      "service": "Postgres",
      "description": "Superuser created on first boot",
      "secret": false,
      "strategy": "default",
      "default": "postgres"
    },
    {
      "key": "SSL_CERT_DAYS",
      "service": "Postgres",
      "description": "SSL certificate expiry in days",
      "secret": false,
      "strategy": "default",
      "default": "820"
    },
    {
      "key": "POSTGRES_PASSWORD",
      "service": "Postgres",
      "description": "Superuser password",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "RAILWAY_DEPLOYMENT_DRAINING_SECONDS",
      "service": "Postgres",
      "description": "Clean shutdown window",
      "secret": false,
      "strategy": "default",
      "default": "60"
    },
    {
      "key": "PORT",
      "service": "hasura",
      "description": "Port Railway probes and routes to",
      "secret": false,
      "strategy": "default",
      "default": "8080"
    },
    {
      "key": "HASURA_GRAPHQL_DEV_MODE",
      "service": "hasura",
      "description": "Hide internal errors from non-admin roles",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "HASURA_GRAPHQL_LOG_LEVEL",
      "service": "hasura",
      "description": "Server log verbosity",
      "secret": false,
      "strategy": "default",
      "default": "info"
    },
    {
      "key": "HASURA_GRAPHQL_SERVER_PORT",
      "service": "hasura",
      "description": "Port the engine listens on",
      "secret": false,
      "strategy": "default",
      "default": "8080"
    },
    {
      "key": "HASURA_GRAPHQL_ADMIN_SECRET",
      "service": "hasura",
      "description": "Admin credential for console and API",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "HASURA_GRAPHQL_DATABASE_URL",
      "service": "hasura",
      "description": "Data source, tracked as `default`",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "HASURA_GRAPHQL_ENABLE_CONSOLE",
      "service": "hasura",
      "description": "Serves the web console at /console",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "HASURA_GRAPHQL_ENABLE_TELEMETRY",
      "service": "hasura",
      "description": "Disable anonymous usage reporting",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "HASURA_GRAPHQL_ENABLED_LOG_TYPES",
      "service": "hasura",
      "description": "Log categories, including generated SQL",
      "secret": false,
      "strategy": "default",
      "default": "startup,http-log,webhook-log,websocket-log,query-log"
    },
    {
      "key": "HASURA_GRAPHQL_CONSOLE_ASSETS_DIR",
      "service": "hasura",
      "description": "Serve console assets from the image",
      "secret": false,
      "strategy": "default",
      "default": "/srv/console-assets"
    },
    {
      "key": "RAILWAY_DEPLOYMENT_DRAINING_SECONDS",
      "service": "hasura",
      "description": "Shutdown window before SIGKILL",
      "secret": false,
      "strategy": "default",
      "default": "30"
    },
    {
      "key": "HASURA_GRAPHQL_METADATA_DATABASE_URL",
      "service": "hasura",
      "description": "Stores the hdb_catalog metadata",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "HASURA_GRAPHQL_GRACEFUL_SHUTDOWN_TIMEOUT",
      "service": "hasura",
      "description": "Seconds to finish in-flight events",
      "secret": false,
      "strategy": "default",
      "default": "25"
    },
    {
      "key": "PGDATA",
      "service": "Postgres-Metadata",
      "description": "Cluster location on the volume",
      "secret": false,
      "strategy": "default",
      "default": "/var/lib/postgresql/data/pgdata"
    },
    {
      "key": "PGHOST",
      "service": "Postgres-Metadata",
      "description": "Data panel alias, not read by the server",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "PGPORT",
      "service": "Postgres-Metadata",
      "description": "Data panel alias, not read by the server",
      "secret": false,
      "strategy": "default",
      "default": "5432"
    },
    {
      "key": "PGUSER",
      "service": "Postgres-Metadata",
      "description": "Data panel alias, not read by the server",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PGDATABASE",
      "service": "Postgres-Metadata",
      "description": "Data panel alias, not read by the server",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PGPASSWORD",
      "service": "Postgres-Metadata",
      "description": "Data panel alias, not read by the server",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "POSTGRES_DB",
      "service": "Postgres-Metadata",
      "description": "Database created on first boot",
      "secret": false,
      "strategy": "default",
      "default": "railway"
    },
    {
      "key": "DATABASE_URL",
      "service": "Postgres-Metadata",
      "description": "Private connection string",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "POSTGRES_USER",
      "service": "Postgres-Metadata",
      "description": "Superuser created on first boot",
      "secret": false,
      "strategy": "default",
      "default": "postgres"
    },
    {
      "key": "SSL_CERT_DAYS",
      "service": "Postgres-Metadata",
      "description": "SSL certificate expiry in days",
      "secret": false,
      "strategy": "default",
      "default": "820"
    },
    {
      "key": "POSTGRES_PASSWORD",
      "service": "Postgres-Metadata",
      "description": "Superuser password",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "RAILWAY_DEPLOYMENT_DRAINING_SECONDS",
      "service": "Postgres-Metadata",
      "description": "Clean shutdown window",
      "secret": false,
      "strategy": "default",
      "default": "60"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "hasura-graphql"
      }
    },
    "cli": "railway deploy --template hasura-graphql",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "7bb65887-51fd-4ad5-baff-e5e8c5955100",
            "serializedConfig": {
              "buckets": {},
              "services": {
                "082a805f-5a1f-4164-a67d-813c6b3e6ef2": {
                  "icon": "https://devicons.railway.app/i/postgresql.svg",
                  "name": "Postgres",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": null,
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "ghcr.io/railwayapp-templates/postgres-ssl:18"
                  },
                  "variables": {
                    "PGDATA": {
                      "isOptional": false,
                      "description": "Cluster location on the volume",
                      "defaultValue": "/var/lib/postgresql/data/pgdata"
                    },
                    "PGHOST": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "${{RAILWAY_PRIVATE_DOMAIN}}"
                    },
                    "PGPORT": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "5432"
                    },
                    "PGUSER": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "${{ POSTGRES_USER }}"
                    },
                    "PGDATABASE": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "${{POSTGRES_DB}}"
                    },
                    "PGPASSWORD": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "${{POSTGRES_PASSWORD}}"
                    },
                    "POSTGRES_DB": {
                      "isOptional": false,
                      "description": "Database created on first boot",
                      "defaultValue": "railway"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "Private connection string",
                      "defaultValue": "postgresql://${{PGUSER}}:${{POSTGRES_PASSWORD}}@${{RAILWAY_PRIVATE_DOMAIN}}:5432/${{PGDATABASE}}"
                    },
                    "POSTGRES_USER": {
                      "isOptional": false,
                      "description": "Superuser created on first boot",
                      "defaultValue": "postgres"
                    },
                    "SSL_CERT_DAYS": {
                      "isOptional": false,
                      "description": "SSL certificate expiry in days",
                      "defaultValue": "820"
                    },
                    "POSTGRES_PASSWORD": {
                      "isOptional": false,
                      "description": "Superuser password",
                      "defaultValue": "{{POSTGRES_PASSWORD}}"
                    },
                    "RAILWAY_DEPLOYMENT_DRAINING_SECONDS": {
                      "isOptional": false,
                      "description": "Clean shutdown window",
                      "defaultValue": "60"
                    }
                  },
                  "volumeMounts": {
                    "082a805f-5a1f-4164-a67d-813c6b3e6ef2": {
                      "mountPath": "/var/lib/postgresql/data"
                    }
                  }
                },
                "426bf42e-0c00-4e72-a1e7-9060b745e256": {
                  "icon": "https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/hasura.svg",
                  "name": "hasura",
                  "deploy": {
                    "startCommand": "",
                    "healthcheckPath": "/healthz",
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "hasura/graphql-engine:latest"
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "Port Railway probes and routes to",
                      "defaultValue": "8080"
                    },
                    "HASURA_GRAPHQL_DEV_MODE": {
                      "isOptional": false,
                      "description": "Hide internal errors from non-admin roles",
                      "defaultValue": "false"
                    },
                    "HASURA_GRAPHQL_LOG_LEVEL": {
                      "isOptional": false,
                      "description": "Server log verbosity",
                      "defaultValue": "info"
                    },
                    "HASURA_GRAPHQL_SERVER_PORT": {
                      "isOptional": false,
                      "description": "Port the engine listens on",
                      "defaultValue": "8080"
                    },
                    "HASURA_GRAPHQL_ADMIN_SECRET": {
                      "isOptional": false,
                      "description": "Admin credential for console and API",
                      "defaultValue": "{{HASURA_GRAPHQL_ADMIN_SECRET}}"
                    },
                    "HASURA_GRAPHQL_DATABASE_URL": {
                      "isOptional": false,
                      "description": "Data source, tracked as `default`",
                      "defaultValue": "${{Postgres.DATABASE_URL}}"
                    },
                    "HASURA_GRAPHQL_ENABLE_CONSOLE": {
                      "isOptional": false,
                      "description": "Serves the web console at /console",
                      "defaultValue": "true"
                    },
                    "HASURA_GRAPHQL_ENABLE_TELEMETRY": {
                      "isOptional": false,
                      "description": "Disable anonymous usage reporting",
                      "defaultValue": "false"
                    },
                    "HASURA_GRAPHQL_ENABLED_LOG_TYPES": {
                      "isOptional": false,
                      "description": "Log categories, including generated SQL",
                      "defaultValue": "startup,http-log,webhook-log,websocket-log,query-log"
                    },
                    "HASURA_GRAPHQL_CONSOLE_ASSETS_DIR": {
                      "isOptional": false,
                      "description": "Serve console assets from the image",
                      "defaultValue": "/srv/console-assets"
                    },
                    "RAILWAY_DEPLOYMENT_DRAINING_SECONDS": {
                      "isOptional": false,
                      "description": "Shutdown window before SIGKILL",
                      "defaultValue": "30"
                    },
                    "HASURA_GRAPHQL_METADATA_DATABASE_URL": {
                      "isOptional": false,
                      "description": "Stores the hdb_catalog metadata",
                      "defaultValue": "${{Postgres-Metadata.DATABASE_URL}}"
                    },
                    "HASURA_GRAPHQL_GRACEFUL_SHUTDOWN_TIMEOUT": {
                      "isOptional": false,
                      "description": "Seconds to finish in-flight events",
                      "defaultValue": "25"
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>:8080": {
                        "port": 8080
                      }
                    }
                  }
                },
                "e810606f-3a0d-4a0e-b21a-92753c0d083b": {
                  "icon": "https://devicons.railway.app/i/postgresql.svg",
                  "name": "Postgres-Metadata",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": null,
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "ghcr.io/railwayapp-templates/postgres-ssl:18"
                  },
                  "variables": {
                    "PGDATA": {
                      "isOptional": false,
                      "description": "Cluster location on the volume",
                      "defaultValue": "/var/lib/postgresql/data/pgdata"
                    },
                    "PGHOST": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "${{RAILWAY_PRIVATE_DOMAIN}}"
                    },
                    "PGPORT": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "5432"
                    },
                    "PGUSER": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "${{ POSTGRES_USER }}"
                    },
                    "PGDATABASE": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "${{POSTGRES_DB}}"
                    },
                    "PGPASSWORD": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "${{POSTGRES_PASSWORD}}"
                    },
                    "POSTGRES_DB": {
                      "isOptional": false,
                      "description": "Database created on first boot",
                      "defaultValue": "railway"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "Private connection string",
                      "defaultValue": "postgresql://${{PGUSER}}:${{POSTGRES_PASSWORD}}@${{RAILWAY_PRIVATE_DOMAIN}}:5432/${{PGDATABASE}}"
                    },
                    "POSTGRES_USER": {
                      "isOptional": false,
                      "description": "Superuser created on first boot",
                      "defaultValue": "postgres"
                    },
                    "SSL_CERT_DAYS": {
                      "isOptional": false,
                      "description": "SSL certificate expiry in days",
                      "defaultValue": "820"
                    },
                    "POSTGRES_PASSWORD": {
                      "isOptional": false,
                      "description": "Superuser password",
                      "defaultValue": "{{POSTGRES_PASSWORD}}"
                    },
                    "RAILWAY_DEPLOYMENT_DRAINING_SECONDS": {
                      "isOptional": false,
                      "description": "Clean shutdown window",
                      "defaultValue": "60"
                    }
                  },
                  "volumeMounts": {
                    "e810606f-3a0d-4a0e-b21a-92753c0d083b": {
                      "mountPath": "/var/lib/postgresql/data"
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {
    "healthcheck": {
      "service": "hasura",
      "method": "GET",
      "path": "/healthz",
      "expect_status": 200
    }
  },
  "resources": {
    "expected_services": 3,
    "needs_volume": true
  },
  "generated_at": "2026-09-20T10:14:37.339Z",
  "generator_version": "0.1.0",
  "status": "validated",
  "validated_at": "2026-09-19T12:42:09.441Z",
  "success_rate_30d": 1,
  "validation": {
    "last_run_id": "run_bc1cc356c6534fd59f54",
    "checks": [
      {
        "name": "workflow_completed",
        "passed": true
      },
      {
        "name": "all_services_deployed",
        "passed": true
      },
      {
        "name": "healthcheck",
        "passed": true
      },
      {
        "name": "stays_up",
        "passed": true
      }
    ],
    "typical_ready_seconds": 70,
    "typical_build_seconds": 0,
    "typical_start_seconds": 10,
    "slowest_service": "hasura"
  }
}
