{
  "manifest_version": "1.0.0",
  "template": {
    "id": "7c8f355b-acb4-4078-a713-cbe9c26629ec",
    "slug": "mediacms",
    "name": "MediaCMS",
    "description": "Self-hosted video platform: uploads, transcoding, HLS, playlists, users.",
    "url": "https://railway.com/deploy/mediacms",
    "upstream": {
      "repo_url": "https://github.com/nomideusz/mediacms-railway"
    }
  },
  "services": [
    {
      "name": "mediacms",
      "source": {
        "repo": "https://github.com/nomideusz/mediacms-railway"
      },
      "needs_volume": true,
      "volume_mount_path": "/home/mediacms.io/mediacms/media_files",
      "http": true
    },
    {
      "name": "postgres",
      "source": {
        "repo": "https://github.com/nomideusz/mediacms-railway"
      },
      "needs_volume": true,
      "volume_mount_path": "/var/lib/postgresql/data",
      "http": false
    },
    {
      "name": "redis",
      "source": {
        "image": "redis:alpine"
      },
      "needs_volume": true,
      "volume_mount_path": "/data",
      "http": false
    }
  ],
  "required_inputs": [
    {
      "key": "SECRET_KEY",
      "service": "mediacms",
      "description": "Default secret key. Auto generated.",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "FRONTEND_HOST",
      "service": "mediacms",
      "description": "Public domain wired automatically. Don't change.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "POSTGRES_HOST",
      "service": "mediacms",
      "description": " Wired automatically to the postgresql service. Don't change.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "ADMIN_PASSWORD",
      "service": "mediacms",
      "description": "Use this password to sign in.",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "REDIS_LOCATION",
      "service": "mediacms",
      "description": "Wired automatically to the redis service. Don't change.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "POSTGRES_PASSWORD",
      "service": "mediacms",
      "description": " Wired automatically to the postgresql service. Don't change.",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "POSTGRES_PASSWORD",
      "service": "postgres",
      "description": "Default Postgres password. Auto generated.",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "mediacms"
      }
    },
    "cli": "railway deploy --template mediacms",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "7c8f355b-acb4-4078-a713-cbe9c26629ec",
            "serializedConfig": {
              "buckets": {},
              "services": {
                "07a21de2-9ac6-47d7-97be-49986378cc89": {
                  "icon": "https://raw.githubusercontent.com/mediacms-io/mediacms/refs/heads/main/frontend/src/static/favicons/apple-touch-icon.png",
                  "name": "mediacms",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": "/",
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "repo": "https://github.com/nomideusz/mediacms-railway",
                    "rootDirectory": "/mediacms"
                  },
                  "variables": {
                    "SECRET_KEY": {
                      "isOptional": false,
                      "description": "Default secret key. Auto generated.",
                      "defaultValue": "{{SECRET_KEY}}"
                    },
                    "FRONTEND_HOST": {
                      "isOptional": false,
                      "description": "Public domain wired automatically. Don't change.",
                      "defaultValue": "https://${{RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "POSTGRES_HOST": {
                      "isOptional": false,
                      "description": " Wired automatically to the postgresql service. Don't change.",
                      "defaultValue": "${{postgres.RAILWAY_PRIVATE_DOMAIN}}"
                    },
                    "ADMIN_PASSWORD": {
                      "isOptional": false,
                      "description": "Use this password to sign in.",
                      "defaultValue": "{{ADMIN_PASSWORD}}"
                    },
                    "REDIS_LOCATION": {
                      "isOptional": false,
                      "description": "Wired automatically to the redis service. Don't change.",
                      "defaultValue": "redis://${{redis.RAILWAY_PRIVATE_DOMAIN}}:6379/1"
                    },
                    "POSTGRES_PASSWORD": {
                      "isOptional": false,
                      "description": " Wired automatically to the postgresql service. Don't change.",
                      "defaultValue": "${{postgres.POSTGRES_PASSWORD}}"
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>": {}
                    }
                  },
                  "volumeMounts": {
                    "07a21de2-9ac6-47d7-97be-49986378cc89": {
                      "mountPath": "/home/mediacms.io/mediacms/media_files"
                    }
                  }
                },
                "0f09bc66-4c38-4342-94cc-cd3b85e7124a": {
                  "icon": "https://www.postgresql.org/media/img/about/press/elephant.png",
                  "name": "postgres",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": null,
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "repo": "https://github.com/nomideusz/mediacms-railway",
                    "rootDirectory": "/postgres"
                  },
                  "variables": {
                    "POSTGRES_PASSWORD": {
                      "isOptional": false,
                      "description": "Default Postgres password. Auto generated.",
                      "defaultValue": "{{POSTGRES_PASSWORD}}"
                    }
                  },
                  "volumeMounts": {
                    "0f09bc66-4c38-4342-94cc-cd3b85e7124a": {
                      "mountPath": "/var/lib/postgresql/data"
                    }
                  }
                },
                "41f128fd-cbc8-4570-8dcc-d6164aa8c3c4": {
                  "icon": "https://media.ffycdn.net/us/redis/MAQLWqeBKmrz2TFQDmA7.svg?mod=v1/resize=2400",
                  "name": "redis",
                  "deploy": {
                    "startCommand": "redis-server --save \"\" --appendonly no",
                    "healthcheckPath": null,
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "redis:alpine"
                  },
                  "variables": {},
                  "volumeMounts": {
                    "41f128fd-cbc8-4570-8dcc-d6164aa8c3c4": {
                      "mountPath": "/data"
                    }
                  },
                  "haTemplateCode": "redis-ha",
                  "haConversionConfig": {
                    "edge": {
                      "label": "Reverse Proxies",
                      "options": [
                        1,
                        2
                      ],
                      "nodeLabel": "HAProxy",
                      "description": "HAProxy instances routing writes to the primary",
                      "defaultValue": 2
                    },
                    "replica": {
                      "label": "Redis Replicas",
                      "options": [
                        2,
                        3,
                        4,
                        5
                      ],
                      "nodeLabel": "Redis",
                      "description": "Nodes running Redis + colocated Sentinel",
                      "defaultValue": 2
                    },
                    "internal": null,
                    "description": "This will convert your Redis instance to an HA cluster with Sentinel failover and HAProxy routing to the primary."
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {
    "healthcheck": {
      "service": "mediacms",
      "method": "GET",
      "path": "/",
      "expect_status": 200
    }
  },
  "resources": {
    "expected_services": 3,
    "needs_volume": true
  },
  "generated_at": "2026-09-10T16:14:52.212Z",
  "generator_version": "0.1.0",
  "status": "validated",
  "validated_at": "2026-09-09T02:12:52.918Z",
  "success_rate_30d": 1,
  "validation": {
    "last_run_id": "run_9e539521aeb040fea0f8",
    "checks": [
      {
        "name": "workflow_completed",
        "passed": true
      },
      {
        "name": "all_services_deployed",
        "passed": true
      },
      {
        "name": "healthcheck",
        "passed": true
      },
      {
        "name": "stays_up",
        "passed": true
      }
    ],
    "typical_ready_seconds": 184,
    "typical_build_seconds": 81,
    "typical_start_seconds": 40,
    "slowest_service": "mediacms"
  }
}
