{
  "manifest_version": "1.0.0",
  "template": {
    "id": "a0ff6344-8eab-47a9-ae65-bc454be4cce3",
    "slug": "synapse",
    "name": "Synapse",
    "description": "Matrix homeserver for decentralised, end-to-end encrypted chat",
    "url": "https://railway.com/deploy/synapse",
    "upstream": {
      "repo_url": "https://github.com/gridalpha/synapse-railway"
    }
  },
  "services": [
    {
      "name": "Redis",
      "source": {
        "image": "redis:8.2"
      },
      "needs_volume": true,
      "volume_mount_path": "/data",
      "http": false
    },
    {
      "name": "Postgres",
      "source": {
        "image": "ghcr.io/railwayapp-templates/postgres-ssl:18"
      },
      "needs_volume": true,
      "volume_mount_path": "/var/lib/postgresql/data",
      "http": false
    },
    {
      "name": "synapse",
      "source": {
        "repo": "https://github.com/gridalpha/synapse-railway"
      },
      "needs_volume": true,
      "volume_mount_path": "/data",
      "http": false
    },
    {
      "name": "proxy",
      "source": {
        "repo": "https://github.com/gridalpha/synapse-railway"
      },
      "needs_volume": false,
      "http": true
    },
    {
      "name": "synapse-worker",
      "source": {
        "repo": "https://github.com/gridalpha/synapse-railway"
      },
      "needs_volume": false,
      "http": false
    }
  ],
  "required_inputs": [
    {
      "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"
    },
    {
      "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": "synapse",
      "description": "HTTP listener probed by the health check",
      "secret": false,
      "strategy": "default",
      "default": "8008"
    },
    {
      "key": "REDISHOST",
      "service": "synapse",
      "description": "Replication bus host",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "REDISPORT",
      "service": "synapse",
      "description": "Replication bus port",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "DATABASE_URL",
      "service": "synapse",
      "description": "Admin connection used to create the database",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "SYNAPSE_ROLE",
      "service": "synapse",
      "description": "Runs the main process",
      "secret": false,
      "strategy": "default",
      "default": "main"
    },
    {
      "key": "REDISPASSWORD",
      "service": "synapse",
      "description": "Replication bus password",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "SYNAPSE_DB_NAME",
      "service": "synapse",
      "description": "Database created with C collation",
      "secret": false,
      "strategy": "default",
      "default": "synapse"
    },
    {
      "key": "SYNAPSE_LOG_LEVEL",
      "service": "synapse",
      "description": "Root logger level",
      "secret": false,
      "strategy": "default",
      "default": "INFO"
    },
    {
      "key": "SYNAPSE_ADMIN_USER",
      "service": "synapse",
      "description": "First admin account, seeded at boot",
      "secret": false,
      "strategy": "default",
      "default": "admin"
    },
    {
      "key": "SYNAPSE_SECRET_SEED",
      "service": "synapse",
      "description": "Seed for all derived signing keys",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "SYNAPSE_SERVER_NAME",
      "service": "synapse",
      "description": "Homeserver identity, permanent",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "SYNAPSE_REPORT_STATS",
      "service": "synapse",
      "description": "Send anonymous stats to matrix.org",
      "secret": false,
      "strategy": "default",
      "default": "0"
    },
    {
      "key": "SYNAPSE_ADMIN_PASSWORD",
      "service": "synapse",
      "description": "First admin password, change after login",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "RAILWAY_DOCKERFILE_PATH",
      "service": "synapse",
      "description": "Dockerfile built for this service",
      "secret": false,
      "strategy": "default",
      "default": "synapse/Dockerfile"
    },
    {
      "key": "SYNAPSE_MAX_UPLOAD_SIZE",
      "service": "synapse",
      "description": "Largest accepted media upload",
      "secret": false,
      "strategy": "default",
      "default": "50M"
    },
    {
      "key": "SYNAPSE_PRESENCE_ENABLED",
      "service": "synapse",
      "description": "Online/offline presence tracking",
      "secret": false,
      "strategy": "default",
      "default": "1"
    },
    {
      "key": "SYNAPSE_FEDERATION_ENABLED",
      "service": "synapse",
      "description": "Join the wider Matrix network",
      "secret": false,
      "strategy": "default",
      "default": "1"
    },
    {
      "key": "SYNAPSE_ENABLE_REGISTRATION",
      "service": "synapse",
      "description": "Open signup, closed by default",
      "secret": false,
      "strategy": "default",
      "default": "0"
    },
    {
      "key": "SYNAPSE_URL_PREVIEW_ENABLED",
      "service": "synapse",
      "description": "Server-side link previews",
      "secret": false,
      "strategy": "default",
      "default": "0"
    },
    {
      "key": "RAILWAY_HEALTHCHECK_TIMEOUT_SEC",
      "service": "synapse",
      "description": "First-boot migration window",
      "secret": false,
      "strategy": "default",
      "default": "600"
    },
    {
      "key": "SYNAPSE_REGISTRATION_REQUIRES_TOKEN",
      "service": "synapse",
      "description": "Require invite token when signup is open",
      "secret": true,
      "strategy": "default",
      "default": "0"
    },
    {
      "key": "PORT",
      "service": "proxy",
      "description": "Public HTTP listener",
      "secret": false,
      "strategy": "default",
      "default": "8080"
    },
    {
      "key": "SYNAPSE_UPSTREAM",
      "service": "proxy",
      "description": "Main process upstream",
      "secret": false,
      "strategy": "default",
      "default": "synapse.railway.internal:8008"
    },
    {
      "key": "SYNAPSE_SECRET_SEED",
      "service": "proxy",
      "description": "Shared seed, referenced by both Synapse services",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "RAILWAY_DOCKERFILE_PATH",
      "service": "proxy",
      "description": "Dockerfile built for this service",
      "secret": false,
      "strategy": "default",
      "default": "proxy/Dockerfile"
    },
    {
      "key": "SYNAPSE_WORKER_UPSTREAM",
      "service": "proxy",
      "description": "Worker upstream",
      "secret": false,
      "strategy": "default",
      "default": "synapse-worker.railway.internal:8008"
    },
    {
      "key": "PORT",
      "service": "synapse-worker",
      "description": "HTTP listener probed by the health check",
      "secret": false,
      "strategy": "default",
      "default": "8008"
    },
    {
      "key": "REDISHOST",
      "service": "synapse-worker",
      "description": "Replication bus host",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "REDISPORT",
      "service": "synapse-worker",
      "description": "Replication bus port",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "DATABASE_URL",
      "service": "synapse-worker",
      "description": "Postgres connection string",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "SYNAPSE_ROLE",
      "service": "synapse-worker",
      "description": "Runs a generic_worker",
      "secret": false,
      "strategy": "default",
      "default": "worker"
    },
    {
      "key": "REDISPASSWORD",
      "service": "synapse-worker",
      "description": "Replication bus password",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "SYNAPSE_DB_NAME",
      "service": "synapse-worker",
      "description": "Same database as the main process",
      "secret": false,
      "strategy": "default",
      "default": "synapse"
    },
    {
      "key": "SYNAPSE_LOG_LEVEL",
      "service": "synapse-worker",
      "description": "Root logger level",
      "secret": false,
      "strategy": "default",
      "default": "INFO"
    },
    {
      "key": "SYNAPSE_MAIN_HOST",
      "service": "synapse-worker",
      "description": "Main process replication endpoint",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "SYNAPSE_SECRET_SEED",
      "service": "synapse-worker",
      "description": "Seed for all derived signing keys",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "SYNAPSE_SERVER_NAME",
      "service": "synapse-worker",
      "description": "Homeserver identity, must match main",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "SYNAPSE_WORKER_NAME",
      "service": "synapse-worker",
      "description": "Worker identity on the replication stream",
      "secret": false,
      "strategy": "default",
      "default": "worker1"
    },
    {
      "key": "SYNAPSE_REPORT_STATS",
      "service": "synapse-worker",
      "description": "Send anonymous stats to matrix.org",
      "secret": false,
      "strategy": "default",
      "default": "0"
    },
    {
      "key": "RAILWAY_DOCKERFILE_PATH",
      "service": "synapse-worker",
      "description": "Same image as the main process",
      "secret": false,
      "strategy": "default",
      "default": "synapse/Dockerfile"
    },
    {
      "key": "SYNAPSE_MAX_UPLOAD_SIZE",
      "service": "synapse-worker",
      "description": "Must match the main process",
      "secret": false,
      "strategy": "default",
      "default": "50M"
    },
    {
      "key": "SYNAPSE_PRESENCE_ENABLED",
      "service": "synapse-worker",
      "description": "Must match the main process",
      "secret": false,
      "strategy": "default",
      "default": "1"
    },
    {
      "key": "SYNAPSE_FEDERATION_ENABLED",
      "service": "synapse-worker",
      "description": "Must match the main process",
      "secret": false,
      "strategy": "default",
      "default": "1"
    },
    {
      "key": "SYNAPSE_ENABLE_REGISTRATION",
      "service": "synapse-worker",
      "description": "Must match the main process",
      "secret": false,
      "strategy": "default",
      "default": "0"
    },
    {
      "key": "SYNAPSE_URL_PREVIEW_ENABLED",
      "service": "synapse-worker",
      "description": "Server-side link previews",
      "secret": false,
      "strategy": "default",
      "default": "0"
    },
    {
      "key": "RAILWAY_HEALTHCHECK_TIMEOUT_SEC",
      "service": "synapse-worker",
      "description": "Waits for the main process schema",
      "secret": false,
      "strategy": "default",
      "default": "600"
    },
    {
      "key": "SYNAPSE_REGISTRATION_REQUIRES_TOKEN",
      "service": "synapse-worker",
      "description": "Must match the main process",
      "secret": true,
      "strategy": "default",
      "default": "0"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "synapse"
      }
    },
    "cli": "railway deploy --template synapse",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "a0ff6344-8eab-47a9-ae65-bc454be4cce3",
            "serializedConfig": {
              "buckets": {},
              "services": {
                "11ea5dd5-c2fe-48f0-ae2c-9e7d2553314d": {
                  "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": {
                    "11ea5dd5-c2fe-48f0-ae2c-9e7d2553314d": {
                      "mountPath": "/data"
                    }
                  }
                },
                "4c46be4c-525e-42b6-b1d2-bc8d9ac56e13": {
                  "icon": "https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/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": {
                    "4c46be4c-525e-42b6-b1d2-bc8d9ac56e13": {
                      "mountPath": "/var/lib/postgresql/data"
                    }
                  }
                },
                "78d37b34-67b8-4e3f-bf89-96736bd9dcd4": {
                  "icon": "https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/matrix-synapse-light.svg",
                  "name": "synapse",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": "/health",
                    "restartPolicyType": "ALWAYS",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "repo": "https://github.com/gridalpha/synapse-railway",
                    "rootDirectory": null
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "HTTP listener probed by the health check",
                      "defaultValue": "8008"
                    },
                    "REDISHOST": {
                      "isOptional": false,
                      "description": "Replication bus host",
                      "defaultValue": "${{Redis.REDISHOST}}"
                    },
                    "REDISPORT": {
                      "isOptional": false,
                      "description": "Replication bus port",
                      "defaultValue": "${{Redis.REDISPORT}}"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "Admin connection used to create the database",
                      "defaultValue": "${{Postgres.DATABASE_URL}}"
                    },
                    "SYNAPSE_ROLE": {
                      "isOptional": false,
                      "description": "Runs the main process",
                      "defaultValue": "main"
                    },
                    "REDISPASSWORD": {
                      "isOptional": false,
                      "description": "Replication bus password",
                      "defaultValue": "${{Redis.REDISPASSWORD}}"
                    },
                    "SYNAPSE_DB_NAME": {
                      "isOptional": false,
                      "description": "Database created with C collation",
                      "defaultValue": "synapse"
                    },
                    "SYNAPSE_LOG_LEVEL": {
                      "isOptional": true,
                      "description": "Root logger level",
                      "defaultValue": "INFO"
                    },
                    "SYNAPSE_ADMIN_USER": {
                      "isOptional": false,
                      "description": "First admin account, seeded at boot",
                      "defaultValue": "admin"
                    },
                    "SYNAPSE_SECRET_SEED": {
                      "isOptional": false,
                      "description": "Seed for all derived signing keys",
                      "defaultValue": "${{proxy.SYNAPSE_SECRET_SEED}}"
                    },
                    "SYNAPSE_SERVER_NAME": {
                      "isOptional": false,
                      "description": "Homeserver identity, permanent",
                      "defaultValue": "${{proxy.RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "SYNAPSE_REPORT_STATS": {
                      "isOptional": true,
                      "description": "Send anonymous stats to matrix.org",
                      "defaultValue": "0"
                    },
                    "SYNAPSE_ADMIN_PASSWORD": {
                      "isOptional": false,
                      "description": "First admin password, change after login",
                      "defaultValue": "{{SYNAPSE_ADMIN_PASSWORD}}"
                    },
                    "RAILWAY_DOCKERFILE_PATH": {
                      "isOptional": false,
                      "description": "Dockerfile built for this service",
                      "defaultValue": "synapse/Dockerfile"
                    },
                    "SYNAPSE_MAX_UPLOAD_SIZE": {
                      "isOptional": true,
                      "description": "Largest accepted media upload",
                      "defaultValue": "50M"
                    },
                    "SYNAPSE_PRESENCE_ENABLED": {
                      "isOptional": true,
                      "description": "Online/offline presence tracking",
                      "defaultValue": "1"
                    },
                    "SYNAPSE_FEDERATION_ENABLED": {
                      "isOptional": true,
                      "description": "Join the wider Matrix network",
                      "defaultValue": "1"
                    },
                    "SYNAPSE_ENABLE_REGISTRATION": {
                      "isOptional": true,
                      "description": "Open signup, closed by default",
                      "defaultValue": "0"
                    },
                    "SYNAPSE_URL_PREVIEW_ENABLED": {
                      "isOptional": true,
                      "description": "Server-side link previews",
                      "defaultValue": "0"
                    },
                    "RAILWAY_HEALTHCHECK_TIMEOUT_SEC": {
                      "isOptional": false,
                      "description": "First-boot migration window",
                      "defaultValue": "600"
                    },
                    "SYNAPSE_REGISTRATION_REQUIRES_TOKEN": {
                      "isOptional": true,
                      "description": "Require invite token when signup is open",
                      "defaultValue": "0"
                    }
                  },
                  "volumeMounts": {
                    "78d37b34-67b8-4e3f-bf89-96736bd9dcd4": {
                      "mountPath": "/data"
                    }
                  }
                },
                "f025b06d-fa08-4d67-87de-50f9623e75eb": {
                  "icon": "https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/caddy.svg",
                  "name": "proxy",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": "/healthz",
                    "restartPolicyType": "ALWAYS",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "repo": "https://github.com/gridalpha/synapse-railway",
                    "rootDirectory": null
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "Public HTTP listener",
                      "defaultValue": "8080"
                    },
                    "SYNAPSE_UPSTREAM": {
                      "isOptional": false,
                      "description": "Main process upstream",
                      "defaultValue": "synapse.railway.internal:8008"
                    },
                    "SYNAPSE_SECRET_SEED": {
                      "isOptional": false,
                      "description": "Shared seed, referenced by both Synapse services",
                      "defaultValue": "{{SYNAPSE_SECRET_SEED}}"
                    },
                    "RAILWAY_DOCKERFILE_PATH": {
                      "isOptional": false,
                      "description": "Dockerfile built for this service",
                      "defaultValue": "proxy/Dockerfile"
                    },
                    "SYNAPSE_WORKER_UPSTREAM": {
                      "isOptional": false,
                      "description": "Worker upstream",
                      "defaultValue": "synapse-worker.railway.internal:8008"
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>:8080": {
                        "port": 8080
                      }
                    }
                  }
                },
                "f235f6da-e12b-4520-ba3f-32d8a9720978": {
                  "icon": "https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/matrix-synapse-light.svg",
                  "name": "synapse-worker",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": "/health",
                    "restartPolicyType": "ALWAYS",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "repo": "https://github.com/gridalpha/synapse-railway",
                    "rootDirectory": null
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "HTTP listener probed by the health check",
                      "defaultValue": "8008"
                    },
                    "REDISHOST": {
                      "isOptional": false,
                      "description": "Replication bus host",
                      "defaultValue": "${{Redis.REDISHOST}}"
                    },
                    "REDISPORT": {
                      "isOptional": false,
                      "description": "Replication bus port",
                      "defaultValue": "${{Redis.REDISPORT}}"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "Postgres connection string",
                      "defaultValue": "${{Postgres.DATABASE_URL}}"
                    },
                    "SYNAPSE_ROLE": {
                      "isOptional": false,
                      "description": "Runs a generic_worker",
                      "defaultValue": "worker"
                    },
                    "REDISPASSWORD": {
                      "isOptional": false,
                      "description": "Replication bus password",
                      "defaultValue": "${{Redis.REDISPASSWORD}}"
                    },
                    "SYNAPSE_DB_NAME": {
                      "isOptional": false,
                      "description": "Same database as the main process",
                      "defaultValue": "synapse"
                    },
                    "SYNAPSE_LOG_LEVEL": {
                      "isOptional": true,
                      "description": "Root logger level",
                      "defaultValue": "INFO"
                    },
                    "SYNAPSE_MAIN_HOST": {
                      "isOptional": false,
                      "description": "Main process replication endpoint",
                      "defaultValue": "${{synapse.RAILWAY_PRIVATE_DOMAIN}}"
                    },
                    "SYNAPSE_SECRET_SEED": {
                      "isOptional": false,
                      "description": "Seed for all derived signing keys",
                      "defaultValue": "${{proxy.SYNAPSE_SECRET_SEED}}"
                    },
                    "SYNAPSE_SERVER_NAME": {
                      "isOptional": false,
                      "description": "Homeserver identity, must match main",
                      "defaultValue": "${{proxy.RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "SYNAPSE_WORKER_NAME": {
                      "isOptional": false,
                      "description": "Worker identity on the replication stream",
                      "defaultValue": "worker1"
                    },
                    "SYNAPSE_REPORT_STATS": {
                      "isOptional": true,
                      "description": "Send anonymous stats to matrix.org",
                      "defaultValue": "0"
                    },
                    "RAILWAY_DOCKERFILE_PATH": {
                      "isOptional": false,
                      "description": "Same image as the main process",
                      "defaultValue": "synapse/Dockerfile"
                    },
                    "SYNAPSE_MAX_UPLOAD_SIZE": {
                      "isOptional": true,
                      "description": "Must match the main process",
                      "defaultValue": "50M"
                    },
                    "SYNAPSE_PRESENCE_ENABLED": {
                      "isOptional": true,
                      "description": "Must match the main process",
                      "defaultValue": "1"
                    },
                    "SYNAPSE_FEDERATION_ENABLED": {
                      "isOptional": true,
                      "description": "Must match the main process",
                      "defaultValue": "1"
                    },
                    "SYNAPSE_ENABLE_REGISTRATION": {
                      "isOptional": true,
                      "description": "Must match the main process",
                      "defaultValue": "0"
                    },
                    "SYNAPSE_URL_PREVIEW_ENABLED": {
                      "isOptional": true,
                      "description": "Server-side link previews",
                      "defaultValue": "0"
                    },
                    "RAILWAY_HEALTHCHECK_TIMEOUT_SEC": {
                      "isOptional": false,
                      "description": "Waits for the main process schema",
                      "defaultValue": "600"
                    },
                    "SYNAPSE_REGISTRATION_REQUIRES_TOKEN": {
                      "isOptional": true,
                      "description": "Must match the main process",
                      "defaultValue": "0"
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {
    "healthcheck": {
      "service": "proxy",
      "method": "GET",
      "path": "/healthz",
      "expect_status": 200
    }
  },
  "resources": {
    "expected_services": 5,
    "needs_volume": true
  },
  "generated_at": "2026-09-16T22:14:52.145Z",
  "generator_version": "0.1.0",
  "status": "validated",
  "validated_at": "2026-09-16T20:17:37.754Z",
  "success_rate_30d": 1,
  "validation": {
    "last_run_id": "run_ffafc658ddaa4644aea3",
    "checks": [
      {
        "name": "workflow_completed",
        "passed": true
      },
      {
        "name": "all_services_deployed",
        "passed": true
      },
      {
        "name": "healthcheck",
        "passed": true
      },
      {
        "name": "stays_up",
        "passed": true
      }
    ],
    "typical_ready_seconds": 248,
    "typical_build_seconds": 122,
    "typical_start_seconds": 21,
    "slowest_service": "synapse-worker"
  }
}
