{
  "manifest_version": "1.0.0",
  "template": {
    "id": "cdcfd96f-b659-4f04-b312-847c9b02b63b",
    "slug": "songbird",
    "name": "Songbird",
    "description": "A secure, lightweight and self-hostable chat platform.",
    "url": "https://railway.com/deploy/songbird"
  },
  "services": [
    {
      "name": "songbird-server",
      "source": {
        "repo": "https://github.com/bllackbull/Songbird"
      },
      "needs_volume": false,
      "http": false
    },
    {
      "name": "songbird-worker",
      "source": {
        "repo": "https://github.com/bllackbull/Songbird"
      },
      "needs_volume": false,
      "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
    }
  ],
  "required_inputs": [
    {
      "key": "APP_ENV",
      "service": "songbird-server",
      "description": "Application environment mode (`production` or `development`).",
      "secret": false,
      "strategy": "default",
      "default": "production"
    },
    {
      "key": "SIGN_UP",
      "service": "songbird-server",
      "description": "Allow open user registration from the UI.",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "DB_CLIENT",
      "service": "songbird-server",
      "description": "Database engine driver (`postgres` or `sqlite3`).",
      "secret": false,
      "strategy": "default",
      "default": "postgres"
    },
    {
      "key": "WORKER_URL",
      "service": "songbird-server",
      "description": "Internal URL for the background media worker service.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "ADMIN_PANEL",
      "service": "songbird-server",
      "description": "Enable the admin dashboard.",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "BIND_ADDRESS",
      "service": "songbird-server",
      "description": "Network interface to bind the HTTP server to.",
      "secret": false,
      "strategy": "default",
      "default": "::"
    },
    {
      "key": "POSTGRES_SSL",
      "service": "songbird-server",
      "description": "Enable SSL for PostgreSQL connections.",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "POSTGRES_URL",
      "service": "songbird-server",
      "description": "PostgreSQL connection URL string.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "APP_PUBLIC_URL",
      "service": "songbird-server",
      "description": "Public origin URL of the app.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "STORAGE_BUCKET",
      "service": "songbird-server",
      "description": "Name of the attached storage bucket.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "STORAGE_DRIVER",
      "service": "songbird-server",
      "description": "File storage backend driver (`remote` or `local`).",
      "secret": false,
      "strategy": "default",
      "default": "remote"
    },
    {
      "key": "STORAGE_REGION",
      "service": "songbird-server",
      "description": "Storage bucket region identifier.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "WEBHOOK_SECRET",
      "service": "songbird-server",
      "description": "Shared secret token to verify internal communication between server and worker.",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "STORAGE_ENDPOINT",
      "service": "songbird-server",
      "description": "API endpoint URL for the storage bucket.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "STORAGE_AUTO_CORS",
      "service": "songbird-server",
      "description": "Automatically configure bucket CORS headers for browser uploads.",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "FILE_UPLOAD_MAX_FILES",
      "service": "songbird-server",
      "description": "Maximum number of attachments per message.",
      "secret": false,
      "strategy": "default",
      "default": "10"
    },
    {
      "key": "STORAGE_ACCESS_KEY_ID",
      "service": "songbird-server",
      "description": "Access key ID for bucket authentication.",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "MESSAGE_FILE_RETENTION",
      "service": "songbird-server",
      "description": "Days to keep uploaded files before auto-cleanup (`0` = forever).",
      "secret": false,
      "strategy": "default",
      "default": "7"
    },
    {
      "key": "MESSAGE_TEXT_RETENTION",
      "service": "songbird-server",
      "description": "Days to keep chat message history before auto-cleanup (`0` = forever).",
      "secret": false,
      "strategy": "default",
      "default": "0"
    },
    {
      "key": "FILE_UPLOAD_MAX_SIZE_MB",
      "service": "songbird-server",
      "description": "Maximum allowed size per uploaded file in MB.",
      "secret": false,
      "strategy": "default",
      "default": "25"
    },
    {
      "key": "STORAGE_PROCESSING_MODE",
      "service": "songbird-server",
      "description": "Media processing workflow mode (`remote`, `local`, or `auto`).",
      "secret": false,
      "strategy": "default",
      "default": "remote"
    },
    {
      "key": "STORAGE_FORCE_PATH_STYLE",
      "service": "songbird-server",
      "description": "Use path-style URLs instead of virtual-hosted URLs.",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "STORAGE_SECRET_ACCESS_KEY",
      "service": "songbird-server",
      "description": "Secret access key for bucket authentication.",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "FILE_UPLOAD_TRANSCODE_VIDEOS",
      "service": "songbird-server",
      "description": "Automatically transcode videos to web-compatible MP4.",
      "secret": false,
      "strategy": "default",
      "default": "true"
    },
    {
      "key": "FILE_UPLOAD_MAX_TOTAL_SIZE_MB",
      "service": "songbird-server",
      "description": "Maximum combined size of attachments per message in MB.",
      "secret": false,
      "strategy": "default",
      "default": "75"
    },
    {
      "key": "APP_ENV",
      "service": "songbird-worker",
      "description": "Worker environment mode (`production` or `development`).",
      "secret": false,
      "strategy": "default",
      "default": "production"
    },
    {
      "key": "WORKER_PORT",
      "service": "songbird-worker",
      "description": "HTTP port the worker process listens on.",
      "secret": false,
      "strategy": "default",
      "default": "8080"
    },
    {
      "key": "STORAGE_BUCKET",
      "service": "songbird-worker",
      "description": "Name of the storage bucket containing media files.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "STORAGE_DRIVER",
      "service": "songbird-worker",
      "description": "File storage backend driver (`remote` or `local`).",
      "secret": false,
      "strategy": "default",
      "default": "remote"
    },
    {
      "key": "STORAGE_REGION",
      "service": "songbird-worker",
      "description": "Storage bucket region identifier.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "WEBHOOK_SECRET",
      "service": "songbird-worker",
      "description": "Shared secret token used to authenticate requests sent to the server.",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "STORAGE_ENDPOINT",
      "service": "songbird-worker",
      "description": "S3-compatible API endpoint URL for reading/writing media.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "WORKER_CONCURRENCY",
      "service": "songbird-worker",
      "description": "Maximum concurrent media transcoding jobs.",
      "secret": false,
      "strategy": "default",
      "default": "2"
    },
    {
      "key": "STORAGE_ACCESS_KEY_ID",
      "service": "songbird-worker",
      "description": "Access key ID for S3 bucket operations.",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "STORAGE_FORCE_PATH_STYLE",
      "service": "songbird-worker",
      "description": "Use path-style URLs for S3 requests.",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "STORAGE_SECRET_ACCESS_KEY",
      "service": "songbird-worker",
      "description": "Secret access key for S3 bucket operations.",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PGDATA",
      "service": "postgres",
      "description": "Location where the database will be initialized",
      "secret": false,
      "strategy": "default",
      "default": "/var/lib/postgresql/data/pgdata"
    },
    {
      "key": "PGHOST",
      "service": "postgres",
      "description": "Railway Private Domain Name.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "PGPORT",
      "service": "postgres",
      "description": "Port to connect to Postgres.",
      "secret": false,
      "strategy": "default",
      "default": "5432"
    },
    {
      "key": "PGUSER",
      "service": "postgres",
      "description": "Required variable for Data panel",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PGDATABASE",
      "service": "postgres",
      "description": "Required variable for the data panel.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "PGPASSWORD",
      "service": "postgres",
      "description": "Required variable for Data panel",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "POSTGRES_DB",
      "service": "postgres",
      "description": "Default database created when image is started.",
      "secret": false,
      "strategy": "default",
      "default": "songbird"
    },
    {
      "key": "DATABASE_URL",
      "service": "postgres",
      "description": "URL to connect to Postgres database.",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "POSTGRES_USER",
      "service": "postgres",
      "description": "User to connect to Postgres DB",
      "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": "Password to connect to DB",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "RAILWAY_DEPLOYMENT_DRAINING_SECONDS",
      "service": "postgres",
      "description": "Allow Postgres to cleanly shut down",
      "secret": false,
      "strategy": "default",
      "default": "60"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "songbird"
      }
    },
    "cli": "railway deploy --template songbird",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "cdcfd96f-b659-4f04-b312-847c9b02b63b",
            "serializedConfig": {
              "buckets": {
                "315bd1bb-e775-4d72-a70e-0326b7d46f5c": {
                  "name": "storage"
                }
              },
              "services": {
                "151565a3-72d2-46c1-93cd-4420cc66cf64": {
                  "icon": "https://raw.githubusercontent.com/bllackbull/Songbird/refs/heads/main/client/public/icons/icon-512-circular.png",
                  "name": "songbird-server",
                  "source": {
                    "repo": "bllackbull/Songbird"
                  },
                  "variables": {
                    "APP_ENV": {
                      "isOptional": true,
                      "description": "Application environment mode (`production` or `development`).",
                      "defaultValue": "production"
                    },
                    "SIGN_UP": {
                      "isOptional": true,
                      "description": "Allow open user registration from the UI.",
                      "defaultValue": "true"
                    },
                    "DB_CLIENT": {
                      "isOptional": false,
                      "description": "Database engine driver (`postgres` or `sqlite3`).",
                      "defaultValue": "postgres"
                    },
                    "WORKER_URL": {
                      "isOptional": false,
                      "description": "Internal URL for the background media worker service.",
                      "defaultValue": "http://${{songbird-worker.RAILWAY_PRIVATE_DOMAIN}}:8080"
                    },
                    "ADMIN_PANEL": {
                      "isOptional": true,
                      "description": "Enable the admin dashboard.",
                      "defaultValue": "true"
                    },
                    "BIND_ADDRESS": {
                      "isOptional": false,
                      "description": "Network interface to bind the HTTP server to.",
                      "defaultValue": "::"
                    },
                    "POSTGRES_SSL": {
                      "isOptional": true,
                      "description": "Enable SSL for PostgreSQL connections.",
                      "defaultValue": "false"
                    },
                    "POSTGRES_URL": {
                      "isOptional": false,
                      "description": "PostgreSQL connection URL string.",
                      "defaultValue": "${{postgres.DATABASE_URL}}"
                    },
                    "APP_PUBLIC_URL": {
                      "isOptional": true,
                      "description": "Public origin URL of the app.",
                      "defaultValue": "https://${{RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "STORAGE_BUCKET": {
                      "isOptional": false,
                      "description": "Name of the attached storage bucket.",
                      "defaultValue": "${{storage.BUCKET}}"
                    },
                    "STORAGE_DRIVER": {
                      "isOptional": false,
                      "description": "File storage backend driver (`remote` or `local`).",
                      "defaultValue": "remote"
                    },
                    "STORAGE_REGION": {
                      "isOptional": false,
                      "description": "Storage bucket region identifier.",
                      "defaultValue": "${{storage.REGION}}"
                    },
                    "WEBHOOK_SECRET": {
                      "isOptional": false,
                      "description": "Shared secret token to verify internal communication between server and worker.",
                      "defaultValue": "{{WEBHOOK_SECRET}}"
                    },
                    "STORAGE_ENDPOINT": {
                      "isOptional": false,
                      "description": "API endpoint URL for the storage bucket.",
                      "defaultValue": "${{storage.ENDPOINT}}"
                    },
                    "STORAGE_AUTO_CORS": {
                      "isOptional": false,
                      "description": "Automatically configure bucket CORS headers for browser uploads.",
                      "defaultValue": "true"
                    },
                    "STORAGE_PUBLIC_URL": {
                      "isOptional": true,
                      "description": "Custom CDN or public URL prefix for downloads.",
                      "defaultValue": ""
                    },
                    "FILE_UPLOAD_MAX_FILES": {
                      "isOptional": true,
                      "description": "Maximum number of attachments per message.",
                      "defaultValue": "10"
                    },
                    "STORAGE_ACCESS_KEY_ID": {
                      "isOptional": false,
                      "description": "Access key ID for bucket authentication.",
                      "defaultValue": "${{storage.ACCESS_KEY_ID}}"
                    },
                    "MESSAGE_FILE_RETENTION": {
                      "isOptional": true,
                      "description": "Days to keep uploaded files before auto-cleanup (`0` = forever).",
                      "defaultValue": "7"
                    },
                    "MESSAGE_TEXT_RETENTION": {
                      "isOptional": true,
                      "description": "Days to keep chat message history before auto-cleanup (`0` = forever).",
                      "defaultValue": "0"
                    },
                    "FILE_UPLOAD_MAX_SIZE_MB": {
                      "isOptional": true,
                      "description": "Maximum allowed size per uploaded file in MB.",
                      "defaultValue": "25"
                    },
                    "STORAGE_PROCESSING_MODE": {
                      "isOptional": false,
                      "description": "Media processing workflow mode (`remote`, `local`, or `auto`).",
                      "defaultValue": "remote"
                    },
                    "STORAGE_FORCE_PATH_STYLE": {
                      "isOptional": false,
                      "description": "Use path-style URLs instead of virtual-hosted URLs.",
                      "defaultValue": "false"
                    },
                    "STORAGE_SECRET_ACCESS_KEY": {
                      "isOptional": false,
                      "description": "Secret access key for bucket authentication.",
                      "defaultValue": "${{storage.SECRET_ACCESS_KEY}}"
                    },
                    "FILE_UPLOAD_TRANSCODE_VIDEOS": {
                      "isOptional": true,
                      "description": "Automatically transcode videos to web-compatible MP4.",
                      "defaultValue": "true"
                    },
                    "FILE_UPLOAD_MAX_TOTAL_SIZE_MB": {
                      "isOptional": true,
                      "description": "Maximum combined size of attachments per message in MB.",
                      "defaultValue": "75"
                    }
                  }
                },
                "2a8a6319-12f8-4ac4-9993-cbc083192108": {
                  "icon": "https://raw.githubusercontent.com/bllackbull/Songbird/refs/heads/main/client/public/icons/icon-512-circular.png",
                  "name": "songbird-worker",
                  "source": {
                    "repo": "bllackbull/Songbird",
                    "rootDirectory": "worker"
                  },
                  "variables": {
                    "APP_ENV": {
                      "isOptional": true,
                      "description": "Worker environment mode (`production` or `development`).",
                      "defaultValue": "production"
                    },
                    "WORKER_PORT": {
                      "isOptional": true,
                      "description": "HTTP port the worker process listens on.",
                      "defaultValue": "8080"
                    },
                    "STORAGE_BUCKET": {
                      "isOptional": false,
                      "description": "Name of the storage bucket containing media files.",
                      "defaultValue": "${{storage.BUCKET}}"
                    },
                    "STORAGE_DRIVER": {
                      "isOptional": false,
                      "description": "File storage backend driver (`remote` or `local`).",
                      "defaultValue": "remote"
                    },
                    "STORAGE_REGION": {
                      "isOptional": false,
                      "description": "Storage bucket region identifier.",
                      "defaultValue": "${{storage.REGION}}"
                    },
                    "WEBHOOK_SECRET": {
                      "isOptional": false,
                      "description": "Shared secret token used to authenticate requests sent to the server.",
                      "defaultValue": "${{songbird-server.WEBHOOK_SECRET}}"
                    },
                    "STORAGE_ENDPOINT": {
                      "isOptional": false,
                      "description": "S3-compatible API endpoint URL for reading/writing media.",
                      "defaultValue": "${{storage.ENDPOINT}}"
                    },
                    "WORKER_CONCURRENCY": {
                      "isOptional": true,
                      "description": "Maximum concurrent media transcoding jobs.",
                      "defaultValue": "2"
                    },
                    "STORAGE_ACCESS_KEY_ID": {
                      "isOptional": false,
                      "description": "Access key ID for S3 bucket operations.",
                      "defaultValue": "${{storage.ACCESS_KEY_ID}}"
                    },
                    "STORAGE_FORCE_PATH_STYLE": {
                      "isOptional": false,
                      "description": "Use path-style URLs for S3 requests.",
                      "defaultValue": "false"
                    },
                    "STORAGE_SECRET_ACCESS_KEY": {
                      "isOptional": false,
                      "description": "Secret access key for S3 bucket operations.",
                      "defaultValue": "${{storage.SECRET_ACCESS_KEY}}"
                    }
                  }
                },
                "50456bbb-2006-406c-b999-9e53998519b5": {
                  "icon": "https://devicons.railway.app/i/postgresql.svg",
                  "name": "postgres",
                  "deploy": {
                    "requiredMountPath": "/var/lib/postgresql/data"
                  },
                  "source": {
                    "image": "ghcr.io/railwayapp-templates/postgres-ssl:18"
                  },
                  "variables": {
                    "PGDATA": {
                      "isOptional": false,
                      "description": "Location where the database will be initialized",
                      "defaultValue": "/var/lib/postgresql/data/pgdata"
                    },
                    "PGHOST": {
                      "isOptional": false,
                      "description": "Railway Private Domain Name.",
                      "defaultValue": "${{RAILWAY_PRIVATE_DOMAIN}}"
                    },
                    "PGPORT": {
                      "isOptional": false,
                      "description": "Port to connect to Postgres.",
                      "defaultValue": "5432"
                    },
                    "PGUSER": {
                      "isOptional": false,
                      "description": "Required variable for Data panel",
                      "defaultValue": "${{ POSTGRES_USER }}"
                    },
                    "PGDATABASE": {
                      "isOptional": false,
                      "description": "Required variable for the data panel.",
                      "defaultValue": "${{POSTGRES_DB}}"
                    },
                    "PGPASSWORD": {
                      "isOptional": false,
                      "description": "Required variable for Data panel",
                      "defaultValue": "${{POSTGRES_PASSWORD}}"
                    },
                    "POSTGRES_DB": {
                      "isOptional": false,
                      "description": "Default database created when image is started.",
                      "defaultValue": "songbird"
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "URL to connect to Postgres database.",
                      "defaultValue": "postgresql://${{PGUSER}}:${{POSTGRES_PASSWORD}}@${{RAILWAY_PRIVATE_DOMAIN}}:5432/${{PGDATABASE}}"
                    },
                    "POSTGRES_USER": {
                      "isOptional": false,
                      "description": "User to connect to Postgres DB",
                      "defaultValue": "postgres"
                    },
                    "SSL_CERT_DAYS": {
                      "isOptional": true,
                      "description": "SSL certificate expiry in days.",
                      "defaultValue": "820"
                    },
                    "POSTGRES_PASSWORD": {
                      "isOptional": false,
                      "description": "Password to connect to DB",
                      "defaultValue": "{{POSTGRES_PASSWORD}}"
                    },
                    "RAILWAY_DEPLOYMENT_DRAINING_SECONDS": {
                      "isOptional": false,
                      "description": "Allow Postgres to cleanly shut down",
                      "defaultValue": "60"
                    }
                  },
                  "volumeMounts": {
                    "50456bbb-2006-406c-b999-9e53998519b5": {
                      "mountPath": "/var/lib/postgresql/data"
                    }
                  },
                  "haTemplateCode": "postgres-ha",
                  "haConversionConfig": {
                    "edge": {
                      "label": "Reverse Proxy",
                      "options": [
                        2,
                        3,
                        4,
                        5
                      ],
                      "nodeLabel": "HAProxy",
                      "description": "Routes traffic to the primary",
                      "defaultValue": 3
                    },
                    "replica": {
                      "label": "Replicas",
                      "options": [
                        2,
                        3,
                        4,
                        5,
                        6,
                        7
                      ],
                      "nodeLabel": "Postgres",
                      "description": "Streaming replicas for automatic failover",
                      "defaultValue": 2
                    },
                    "internal": {
                      "label": "Coordinator Nodes",
                      "options": [
                        3,
                        5,
                        7,
                        9
                      ],
                      "nodeLabel": "etcd",
                      "defaultValue": 3
                    },
                    "description": "This will convert your Postgres database to an HA cluster with Patroni failover and etcd consensus."
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {},
  "resources": {
    "expected_services": 3,
    "needs_volume": true
  },
  "generated_at": "2026-09-08T18:46:46.960Z",
  "generator_version": "0.1.0",
  "status": "validated",
  "validated_at": "2026-09-08T18:51:19.189Z",
  "success_rate_30d": 1,
  "validation": {
    "last_run_id": "run_060102b634c048bd8bac",
    "checks": [
      {
        "name": "workflow_completed",
        "passed": true
      },
      {
        "name": "all_services_deployed",
        "passed": true
      },
      {
        "name": "stays_up",
        "passed": true
      }
    ],
    "typical_ready_seconds": 201,
    "typical_build_seconds": 102,
    "typical_start_seconds": 11,
    "slowest_service": "songbird-server"
  }
}
