{
  "manifest_version": "1.0.0",
  "template": {
    "id": "ebb8dba5-aea5-49f8-9172-fecf454789cd",
    "slug": "hyperdx-otel",
    "name": "HyperDX",
    "description": "Search your app's logs, traces and metrics in one place",
    "url": "https://railway.com/deploy/hyperdx-otel",
    "upstream": {
      "repo_url": "https://github.com/gridalpha/hyperdx-railway"
    }
  },
  "services": [
    {
      "name": "MongoDB",
      "source": {
        "image": "mongo:8.0"
      },
      "needs_volume": true,
      "volume_mount_path": "/data/db",
      "http": false
    },
    {
      "name": "clickhouse",
      "source": {
        "repo": "https://github.com/gridalpha/hyperdx-railway"
      },
      "needs_volume": true,
      "volume_mount_path": "/var/lib/clickhouse",
      "http": false
    },
    {
      "name": "hyperdx",
      "source": {
        "repo": "https://github.com/gridalpha/hyperdx-railway"
      },
      "needs_volume": false,
      "http": true
    },
    {
      "name": "otel-collector",
      "source": {
        "image": "clickhouse/clickstack-otel-collector:2.37.0"
      },
      "needs_volume": false,
      "tcp_ports": [
        4317
      ],
      "http": true
    }
  ],
  "required_inputs": [
    {
      "key": "MONGOHOST",
      "service": "MongoDB",
      "description": "Data panel alias, not read by the server",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "MONGOPORT",
      "service": "MongoDB",
      "description": "Data panel alias, not read by the server",
      "secret": false,
      "strategy": "default",
      "default": "27017"
    },
    {
      "key": "MONGOUSER",
      "service": "MongoDB",
      "description": "Data panel alias, not read by the server",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "MONGO_URL",
      "service": "MongoDB",
      "description": "Private connection string",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "MONGOPASSWORD",
      "service": "MongoDB",
      "description": "Data panel alias, not read by the server",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "MONGO_INITDB_ROOT_PASSWORD",
      "service": "MongoDB",
      "description": "Root user password, set during initialization",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "MONGO_INITDB_ROOT_USERNAME",
      "service": "MongoDB",
      "description": "User created during initialization, given the root role",
      "secret": false,
      "strategy": "default",
      "default": "mongo"
    },
    {
      "key": "PORT",
      "service": "clickhouse",
      "description": "HTTP port, used by the health check",
      "secret": false,
      "strategy": "default",
      "default": "8123"
    },
    {
      "key": "CLICKHOUSE_USER",
      "service": "clickhouse",
      "description": "Account the app and collector use",
      "secret": false,
      "strategy": "default",
      "default": "default"
    },
    {
      "key": "CLICKHOUSE_PASSWORD",
      "service": "clickhouse",
      "description": "Hashed into users.d at boot",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "RAILWAY_DOCKERFILE_PATH",
      "service": "clickhouse",
      "description": "Selects the ClickHouse image in the repo",
      "secret": false,
      "strategy": "default",
      "default": "clickhouse/Dockerfile"
    },
    {
      "key": "RAILWAY_DEPLOYMENT_DRAINING_SECONDS",
      "service": "clickhouse",
      "description": "Flush window on redeploy",
      "secret": false,
      "strategy": "default",
      "default": "30"
    },
    {
      "key": "PORT",
      "service": "hyperdx",
      "description": "API port, used by the health check",
      "secret": false,
      "strategy": "default",
      "default": "8000"
    },
    {
      "key": "MONGO_URI",
      "service": "hyperdx",
      "description": "Metadata database",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "CLICKHOUSE_HOST",
      "service": "hyperdx",
      "description": "Private ClickHouse hostname",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "CLICKHOUSE_PORT",
      "service": "hyperdx",
      "description": "ClickHouse HTTP port",
      "secret": false,
      "strategy": "default",
      "default": "8123"
    },
    {
      "key": "CLICKHOUSE_USER",
      "service": "hyperdx",
      "description": "ClickHouse account",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "HYPERDX_API_PORT",
      "service": "hyperdx",
      "description": "Express API listener",
      "secret": false,
      "strategy": "default",
      "default": "8000"
    },
    {
      "key": "HYPERDX_APP_PORT",
      "service": "hyperdx",
      "description": "Next.js UI listener, the public target port",
      "secret": false,
      "strategy": "default",
      "default": "8080"
    },
    {
      "key": "HYPERDX_LOG_LEVEL",
      "service": "hyperdx",
      "description": "Application log verbosity",
      "secret": false,
      "strategy": "default",
      "default": "info"
    },
    {
      "key": "CLICKHOUSE_PASSWORD",
      "service": "hyperdx",
      "description": "ClickHouse password",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "USAGE_STATS_ENABLED",
      "service": "hyperdx",
      "description": "Anonymous usage reporting off",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "EXPRESS_SESSION_SECRET",
      "service": "hyperdx",
      "description": "Session cookie signing key",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "RAILWAY_DOCKERFILE_PATH",
      "service": "hyperdx",
      "description": "Selects the app image in the repo",
      "secret": false,
      "strategy": "default",
      "default": "app/Dockerfile"
    },
    {
      "key": "RAILWAY_DEPLOYMENT_DRAINING_SECONDS",
      "service": "hyperdx",
      "description": "Clean shutdown window",
      "secret": false,
      "strategy": "default",
      "default": "15"
    },
    {
      "key": "PORT",
      "service": "otel-collector",
      "description": "Health check extension port",
      "secret": false,
      "strategy": "default",
      "default": "13133"
    },
    {
      "key": "CLICKHOUSE_USER",
      "service": "otel-collector",
      "description": "ClickHouse account",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "OPAMP_SERVER_URL",
      "service": "otel-collector",
      "description": "Managed config source",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "HYPERDX_LOG_LEVEL",
      "service": "otel-collector",
      "description": "Collector log verbosity",
      "secret": false,
      "strategy": "default",
      "default": "info"
    },
    {
      "key": "CLICKHOUSE_ENDPOINT",
      "service": "otel-collector",
      "description": "Native write endpoint",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "CLICKHOUSE_PASSWORD",
      "service": "otel-collector",
      "description": "ClickHouse password",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "HYPERDX_OTEL_EXPORTER_TABLES_TTL",
      "service": "otel-collector",
      "description": "Telemetry retention, 30 days",
      "secret": false,
      "strategy": "default",
      "default": "720h"
    },
    {
      "key": "HYPERDX_OTEL_EXPORTER_CLICKHOUSE_DATABASE",
      "service": "otel-collector",
      "description": "Target database",
      "secret": false,
      "strategy": "default",
      "default": "default"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "hyperdx-otel"
      }
    },
    "cli": "railway deploy --template hyperdx-otel",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "ebb8dba5-aea5-49f8-9172-fecf454789cd",
            "serializedConfig": {
              "buckets": {},
              "services": {
                "0c9722f2-c1d4-40c9-8762-9c2e93769e31": {
                  "icon": "https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/mongodb.svg",
                  "name": "MongoDB",
                  "deploy": {
                    "startCommand": "docker-entrypoint.sh mongod --ipv6 --bind_ip ::,0.0.0.0 --setParameter diagnosticDataCollectionEnabled=false",
                    "healthcheckPath": null,
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "mongo:8.0"
                  },
                  "variables": {
                    "MONGOHOST": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "${{RAILWAY_PRIVATE_DOMAIN}}"
                    },
                    "MONGOPORT": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "27017"
                    },
                    "MONGOUSER": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "${{MONGO_INITDB_ROOT_USERNAME}}"
                    },
                    "MONGO_URL": {
                      "isOptional": false,
                      "description": "Private connection string",
                      "defaultValue": "mongodb://${{MONGO_INITDB_ROOT_USERNAME}}:${{MONGO_INITDB_ROOT_PASSWORD}}@${{RAILWAY_PRIVATE_DOMAIN}}:27017"
                    },
                    "MONGOPASSWORD": {
                      "isOptional": false,
                      "description": "Data panel alias, not read by the server",
                      "defaultValue": "${{MONGO_INITDB_ROOT_PASSWORD}}"
                    },
                    "MONGO_INITDB_ROOT_PASSWORD": {
                      "isOptional": false,
                      "description": "Root user password, set during initialization",
                      "defaultValue": "{{MONGO_INITDB_ROOT_PASSWORD}}"
                    },
                    "MONGO_INITDB_ROOT_USERNAME": {
                      "isOptional": false,
                      "description": "User created during initialization, given the root role",
                      "defaultValue": "mongo"
                    }
                  },
                  "volumeMounts": {
                    "0c9722f2-c1d4-40c9-8762-9c2e93769e31": {
                      "mountPath": "/data/db"
                    }
                  }
                },
                "37a08e37-aa73-410d-9ca7-3c082387690e": {
                  "icon": "https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/clickhouse.svg",
                  "name": "clickhouse",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": "/ping",
                    "restartPolicyType": "ALWAYS",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "repo": "https://github.com/gridalpha/hyperdx-railway",
                    "rootDirectory": null
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "HTTP port, used by the health check",
                      "defaultValue": "8123"
                    },
                    "CLICKHOUSE_USER": {
                      "isOptional": false,
                      "description": "Account the app and collector use",
                      "defaultValue": "default"
                    },
                    "CLICKHOUSE_PASSWORD": {
                      "isOptional": false,
                      "description": "Hashed into users.d at boot",
                      "defaultValue": "{{CLICKHOUSE_PASSWORD}}"
                    },
                    "RAILWAY_DOCKERFILE_PATH": {
                      "isOptional": false,
                      "description": "Selects the ClickHouse image in the repo",
                      "defaultValue": "clickhouse/Dockerfile"
                    },
                    "RAILWAY_DEPLOYMENT_DRAINING_SECONDS": {
                      "isOptional": false,
                      "description": "Flush window on redeploy",
                      "defaultValue": "30"
                    }
                  },
                  "volumeMounts": {
                    "37a08e37-aa73-410d-9ca7-3c082387690e": {
                      "mountPath": "/var/lib/clickhouse"
                    }
                  }
                },
                "c4c8b087-fe95-4f51-aa6f-21c21414a05c": {
                  "icon": "https://raw.githubusercontent.com/hyperdxio/hyperdx/main/packages/app/public/favicons/hyperdx/favicon.svg",
                  "name": "hyperdx",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": "/ready",
                    "restartPolicyType": "ALWAYS",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "repo": "https://github.com/gridalpha/hyperdx-railway",
                    "rootDirectory": null
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "API port, used by the health check",
                      "defaultValue": "8000"
                    },
                    "MONGO_URI": {
                      "isOptional": false,
                      "description": "Metadata database",
                      "defaultValue": "${{MongoDB.MONGO_URL}}/hyperdx?authSource=admin"
                    },
                    "CLICKHOUSE_HOST": {
                      "isOptional": false,
                      "description": "Private ClickHouse hostname",
                      "defaultValue": "${{clickhouse.RAILWAY_PRIVATE_DOMAIN}}"
                    },
                    "CLICKHOUSE_PORT": {
                      "isOptional": false,
                      "description": "ClickHouse HTTP port",
                      "defaultValue": "8123"
                    },
                    "CLICKHOUSE_USER": {
                      "isOptional": false,
                      "description": "ClickHouse account",
                      "defaultValue": "${{clickhouse.CLICKHOUSE_USER}}"
                    },
                    "HYPERDX_API_PORT": {
                      "isOptional": false,
                      "description": "Express API listener",
                      "defaultValue": "8000"
                    },
                    "HYPERDX_APP_PORT": {
                      "isOptional": false,
                      "description": "Next.js UI listener, the public target port",
                      "defaultValue": "8080"
                    },
                    "HYPERDX_LOG_LEVEL": {
                      "isOptional": false,
                      "description": "Application log verbosity",
                      "defaultValue": "info"
                    },
                    "CLICKHOUSE_PASSWORD": {
                      "isOptional": false,
                      "description": "ClickHouse password",
                      "defaultValue": "${{clickhouse.CLICKHOUSE_PASSWORD}}"
                    },
                    "USAGE_STATS_ENABLED": {
                      "isOptional": false,
                      "description": "Anonymous usage reporting off",
                      "defaultValue": "false"
                    },
                    "EXPRESS_SESSION_SECRET": {
                      "isOptional": false,
                      "description": "Session cookie signing key",
                      "defaultValue": "{{EXPRESS_SESSION_SECRET}}"
                    },
                    "RAILWAY_DOCKERFILE_PATH": {
                      "isOptional": false,
                      "description": "Selects the app image in the repo",
                      "defaultValue": "app/Dockerfile"
                    },
                    "RAILWAY_DEPLOYMENT_DRAINING_SECONDS": {
                      "isOptional": false,
                      "description": "Clean shutdown window",
                      "defaultValue": "15"
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>:8080": {
                        "port": 8080
                      }
                    }
                  }
                },
                "e9338052-9989-4109-a85d-9bd1d185f6ba": {
                  "icon": "https://raw.githubusercontent.com/open-telemetry/opentelemetry.io/main/static/img/logos/opentelemetry-icon-color.png",
                  "name": "otel-collector",
                  "deploy": {
                    "startCommand": "/bin/sh -c 'case \"$CLICKHOUSE_ENDPOINT\" in \"\"|tcp://:*) CLICKHOUSE_ENDPOINT=\"tcp://clickhouse.railway.internal:9000?dial_timeout=10s\";; esac; case \"$OPAMP_SERVER_URL\" in \"\"|http://:*) OPAMP_SERVER_URL=\"http://hyperdx.railway.internal:4320\";; esac; export CLICKHOUSE_ENDPOINT OPAMP_SERVER_URL; echo \"collector: clickhouse=$CLICKHOUSE_ENDPOINT opamp=$OPAMP_SERVER_URL\"; exec /entrypoint.sh /opampsupervisor'",
                    "healthcheckPath": "/",
                    "restartPolicyType": "ALWAYS",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "clickhouse/clickstack-otel-collector:2.37.0"
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "Health check extension port",
                      "defaultValue": "13133"
                    },
                    "CLICKHOUSE_USER": {
                      "isOptional": false,
                      "description": "ClickHouse account",
                      "defaultValue": "${{clickhouse.CLICKHOUSE_USER}}"
                    },
                    "OPAMP_SERVER_URL": {
                      "isOptional": false,
                      "description": "Managed config source",
                      "defaultValue": "http://${{hyperdx.RAILWAY_PRIVATE_DOMAIN}}:4320"
                    },
                    "HYPERDX_LOG_LEVEL": {
                      "isOptional": false,
                      "description": "Collector log verbosity",
                      "defaultValue": "info"
                    },
                    "CLICKHOUSE_ENDPOINT": {
                      "isOptional": false,
                      "description": "Native write endpoint",
                      "defaultValue": "tcp://${{clickhouse.RAILWAY_PRIVATE_DOMAIN}}:9000?dial_timeout=10s"
                    },
                    "CLICKHOUSE_PASSWORD": {
                      "isOptional": false,
                      "description": "ClickHouse password",
                      "defaultValue": "${{clickhouse.CLICKHOUSE_PASSWORD}}"
                    },
                    "HYPERDX_OTEL_EXPORTER_TABLES_TTL": {
                      "isOptional": false,
                      "description": "Telemetry retention, 30 days",
                      "defaultValue": "720h"
                    },
                    "HYPERDX_OTEL_EXPORTER_CLICKHOUSE_DATABASE": {
                      "isOptional": false,
                      "description": "Target database",
                      "defaultValue": "default"
                    }
                  },
                  "networking": {
                    "tcpProxies": {
                      "4317": {}
                    },
                    "serviceDomains": {
                      "<hasDomain>:4318": {
                        "port": 4318
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {
    "healthcheck": {
      "service": "hyperdx",
      "method": "GET",
      "path": "/ready",
      "expect_status": 200
    }
  },
  "resources": {
    "expected_services": 4,
    "needs_volume": true
  },
  "generated_at": "2026-09-22T22:14:50.114Z",
  "generator_version": "0.1.0",
  "status": "degraded",
  "validated_at": "2026-09-21T19:59:55.431Z",
  "success_rate_30d": 0,
  "validation": {
    "last_run_id": "run_7228dc94785f488c9f1c",
    "checks": [
      {
        "name": "workflow_completed",
        "passed": true
      },
      {
        "name": "all_services_deployed",
        "passed": true
      },
      {
        "name": "healthcheck",
        "passed": false,
        "detail": "got 404, expected 200"
      },
      {
        "name": "stays_up",
        "passed": true
      }
    ]
  }
}
