{
  "manifest_version": "1.0.0",
  "template": {
    "id": "5509c9be-912c-4af2-a7c9-057acf4ae07d",
    "slug": "jellystat",
    "name": "Jellystat",
    "description": "Jellyfin viewing statistics with PostgreSQL and persistent backup storage.",
    "url": "https://railway.com/deploy/jellystat",
    "upstream": {
      "image": "cyfershepard/jellystat:1.1.12@sha256:e61c759ec706da378bc8374e797da1dfd298ab30f804cefd82d192c301a888c7"
    }
  },
  "services": [
    {
      "name": "jellystat",
      "source": {
        "image": "cyfershepard/jellystat:1.1.12@sha256:e61c759ec706da378bc8374e797da1dfd298ab30f804cefd82d192c301a888c7"
      },
      "needs_volume": true,
      "volume_mount_path": "/app/backend/backup-data",
      "http": true
    },
    {
      "name": "postgres",
      "source": {
        "image": "postgres:17@sha256:f4c66b820c6f974249089d3d16d86a3698eae11e8746eb6644b2271031e91232"
      },
      "needs_volume": true,
      "volume_mount_path": "/var/lib/postgresql/data",
      "http": false
    }
  ],
  "required_inputs": [
    {
      "key": "TZ",
      "service": "jellystat",
      "description": "Tz for jellystat. The supplied value follows the pinned upstream deployment; change only with its configuration guide.",
      "secret": false,
      "strategy": "default",
      "default": "Etc/UTC"
    },
    {
      "key": "PORT",
      "service": "jellystat",
      "description": "HTTP port inside this service. Keep the default to match its Railway public port and health check.",
      "secret": false,
      "strategy": "default",
      "default": "3000"
    },
    {
      "key": "JS_USER",
      "service": "jellystat",
      "description": "Js user for jellystat. The supplied value follows the pinned upstream deployment; change only with its configuration guide.",
      "secret": false,
      "strategy": "default",
      "default": "admin"
    },
    {
      "key": "JWT_SECRET",
      "service": "jellystat",
      "description": "Generated jwt secret. Keep private and preserve with backups.",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "JS_PASSWORD",
      "service": "jellystat",
      "description": "Generated js password. Keep private and preserve with backups.",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "POSTGRES_DB",
      "service": "jellystat",
      "description": "Initial PostgreSQL database name, or the matching database selected by the application.",
      "secret": false,
      "strategy": "default",
      "default": "jfstat"
    },
    {
      "key": "POSTGRES_IP",
      "service": "jellystat",
      "description": "Postgres ip resolved automatically from the linked service. Keep this reference when using the included topology.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "JS_LISTEN_IP",
      "service": "jellystat",
      "description": "Js listen ip for jellystat. The supplied value follows the pinned upstream deployment; change only with its configuration guide.",
      "secret": false,
      "strategy": "default",
      "default": "::"
    },
    {
      "key": "POSTGRES_PORT",
      "service": "jellystat",
      "description": "Private PostgreSQL TCP port. Keep 5432.",
      "secret": false,
      "strategy": "default",
      "default": "5432"
    },
    {
      "key": "POSTGRES_USER",
      "service": "jellystat",
      "description": "PostgreSQL initialization user, or the matching connection user for the private database.",
      "secret": false,
      "strategy": "default",
      "default": "jfstat"
    },
    {
      "key": "POSTGRES_PASSWORD",
      "service": "jellystat",
      "description": "PostgreSQL password. Generated for the database and referenced by dependent services; keep private.",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PGDATA",
      "service": "postgres",
      "description": "PostgreSQL data directory within the persistent volume. Do not change on an existing database.",
      "secret": false,
      "strategy": "default",
      "default": "/var/lib/postgresql/data/pgdata"
    },
    {
      "key": "POSTGRES_DB",
      "service": "postgres",
      "description": "Initial PostgreSQL database name, or the matching database selected by the application.",
      "secret": false,
      "strategy": "default",
      "default": "jfstat"
    },
    {
      "key": "POSTGRES_USER",
      "service": "postgres",
      "description": "PostgreSQL initialization user, or the matching connection user for the private database.",
      "secret": false,
      "strategy": "default",
      "default": "jfstat"
    },
    {
      "key": "POSTGRES_PASSWORD",
      "service": "postgres",
      "description": "PostgreSQL password. Generated for the database and referenced by dependent services; keep private.",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "jellystat"
      }
    },
    "cli": "railway deploy --template jellystat",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "5509c9be-912c-4af2-a7c9-057acf4ae07d",
            "serializedConfig": {
              "services": {
                "3d977b27-454e-5e54-af9e-724a79ba771f": {
                  "name": "jellystat",
                  "deploy": {
                    "healthcheckPath": "/auth/isConfigured",
                    "requiredMountPath": "/app/backend/backup-data",
                    "restartPolicyType": "ON_FAILURE",
                    "healthcheckTimeout": 600,
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "cyfershepard/jellystat:1.1.12@sha256:e61c759ec706da378bc8374e797da1dfd298ab30f804cefd82d192c301a888c7"
                  },
                  "variables": {
                    "TZ": {
                      "isOptional": false,
                      "description": "Tz for jellystat. The supplied value follows the pinned upstream deployment; change only with its configuration guide.",
                      "defaultValue": "Etc/UTC"
                    },
                    "PORT": {
                      "isOptional": false,
                      "description": "HTTP port inside this service. Keep the default to match its Railway public port and health check.",
                      "defaultValue": "3000"
                    },
                    "JS_USER": {
                      "isOptional": false,
                      "description": "Js user for jellystat. The supplied value follows the pinned upstream deployment; change only with its configuration guide.",
                      "defaultValue": "admin"
                    },
                    "JWT_SECRET": {
                      "isOptional": false,
                      "description": "Generated jwt secret. Keep private and preserve with backups.",
                      "defaultValue": "{{JWT_SECRET}}"
                    },
                    "JS_PASSWORD": {
                      "isOptional": false,
                      "description": "Generated js password. Keep private and preserve with backups.",
                      "defaultValue": "{{JS_PASSWORD}}"
                    },
                    "POSTGRES_DB": {
                      "isOptional": false,
                      "description": "Initial PostgreSQL database name, or the matching database selected by the application.",
                      "defaultValue": "jfstat"
                    },
                    "POSTGRES_IP": {
                      "isOptional": false,
                      "description": "Postgres ip resolved automatically from the linked service. Keep this reference when using the included topology.",
                      "defaultValue": "${{postgres.RAILWAY_PRIVATE_DOMAIN}}"
                    },
                    "JS_LISTEN_IP": {
                      "isOptional": false,
                      "description": "Js listen ip for jellystat. The supplied value follows the pinned upstream deployment; change only with its configuration guide.",
                      "defaultValue": "::"
                    },
                    "POSTGRES_PORT": {
                      "isOptional": false,
                      "description": "Private PostgreSQL TCP port. Keep 5432.",
                      "defaultValue": "5432"
                    },
                    "POSTGRES_USER": {
                      "isOptional": false,
                      "description": "PostgreSQL initialization user, or the matching connection user for the private database.",
                      "defaultValue": "jfstat"
                    },
                    "POSTGRES_PASSWORD": {
                      "isOptional": false,
                      "description": "PostgreSQL password. Generated for the database and referenced by dependent services; keep private.",
                      "defaultValue": "${{postgres.POSTGRES_PASSWORD}}"
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>:3000": {
                        "port": 3000
                      }
                    }
                  },
                  "volumeMounts": {
                    "31a3806c-c2fa-5220-ab64-942abfbabbe6": {
                      "mountPath": "/app/backend/backup-data"
                    }
                  }
                },
                "835c11f7-7315-562a-b7d3-acf596d23c12": {
                  "name": "postgres",
                  "deploy": {
                    "requiredMountPath": "/var/lib/postgresql/data",
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "postgres:17@sha256:f4c66b820c6f974249089d3d16d86a3698eae11e8746eb6644b2271031e91232"
                  },
                  "variables": {
                    "PGDATA": {
                      "isOptional": false,
                      "description": "PostgreSQL data directory within the persistent volume. Do not change on an existing database.",
                      "defaultValue": "/var/lib/postgresql/data/pgdata"
                    },
                    "POSTGRES_DB": {
                      "isOptional": false,
                      "description": "Initial PostgreSQL database name, or the matching database selected by the application.",
                      "defaultValue": "jfstat"
                    },
                    "POSTGRES_USER": {
                      "isOptional": false,
                      "description": "PostgreSQL initialization user, or the matching connection user for the private database.",
                      "defaultValue": "jfstat"
                    },
                    "POSTGRES_PASSWORD": {
                      "isOptional": false,
                      "description": "PostgreSQL password. Generated for the database and referenced by dependent services; keep private.",
                      "defaultValue": "{{POSTGRES_PASSWORD}}"
                    }
                  },
                  "networking": {
                    "serviceDomains": {}
                  },
                  "volumeMounts": {
                    "fce22db3-b075-5a94-ba1f-d1525bbeaff1": {
                      "mountPath": "/var/lib/postgresql/data"
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {
    "healthcheck": {
      "service": "jellystat",
      "method": "GET",
      "path": "/auth/isConfigured",
      "expect_status": 200
    }
  },
  "resources": {
    "expected_services": 2,
    "needs_volume": true
  },
  "generated_at": "2026-09-19T10:14:38.021Z",
  "generator_version": "0.1.0",
  "status": "validated",
  "validated_at": "2026-09-19T07:54:11.321Z",
  "success_rate_30d": 1,
  "validation": {
    "last_run_id": "run_5fb565e7a2854cb79f26",
    "checks": [
      {
        "name": "workflow_completed",
        "passed": true
      },
      {
        "name": "all_services_deployed",
        "passed": true
      },
      {
        "name": "healthcheck",
        "passed": true
      },
      {
        "name": "stays_up",
        "passed": true
      }
    ],
    "typical_ready_seconds": 58,
    "typical_build_seconds": 0,
    "typical_start_seconds": 10,
    "slowest_service": "jellystat"
  }
}
