{
  "manifest_version": "1.0.0",
  "template": {
    "id": "a9a57901-7415-4209-b714-784bcd2a7c3e",
    "slug": "archivebox-railway",
    "name": "ArchiveBox",
    "description": "Deploy ArchiveBox on Railway: archive URLs to HTML, PDF, WARC & screenshots",
    "url": "https://railway.com/deploy/archivebox-railway",
    "upstream": {
      "repo_url": "https://github.com/gridalpha/archivebox-railway"
    }
  },
  "services": [
    {
      "name": "archivebox",
      "source": {
        "repo": "https://github.com/gridalpha/archivebox-railway"
      },
      "needs_volume": true,
      "volume_mount_path": "/data",
      "http": true
    },
    {
      "name": "sonic",
      "source": {
        "image": "valeriansaliou/sonic:v1.8.1"
      },
      "needs_volume": true,
      "volume_mount_path": "/var/lib/sonic/store",
      "http": false
    }
  ],
  "required_inputs": [
    {
      "key": "PORT",
      "service": "archivebox",
      "description": "HTTP port the server binds",
      "secret": false,
      "strategy": "default",
      "default": "8000"
    },
    {
      "key": "TIMEOUT",
      "service": "archivebox",
      "description": "Seconds allowed per extractor",
      "secret": false,
      "strategy": "default",
      "default": "120"
    },
    {
      "key": "SAVE_MEDIA",
      "service": "archivebox",
      "description": "yt-dlp media capture, off by default",
      "secret": false,
      "strategy": "default",
      "default": "False"
    },
    {
      "key": "SECRET_KEY",
      "service": "archivebox",
      "description": "Django session signing key",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "PUBLIC_INDEX",
      "service": "archivebox",
      "description": "Hide the snapshot list from anonymous visitors",
      "secret": false,
      "strategy": "default",
      "default": "False"
    },
    {
      "key": "ADMIN_PASSWORD",
      "service": "archivebox",
      "description": "Superuser password, override to choose one",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "ADMIN_USERNAME",
      "service": "archivebox",
      "description": "Superuser created on first boot",
      "secret": false,
      "strategy": "default",
      "default": "admin"
    },
    {
      "key": "MEDIA_MAX_SIZE",
      "service": "archivebox",
      "description": "Per-file media size ceiling",
      "secret": false,
      "strategy": "default",
      "default": "250m"
    },
    {
      "key": "PUBLIC_ADD_VIEW",
      "service": "archivebox",
      "description": "Only logged-in users may submit URLs",
      "secret": false,
      "strategy": "default",
      "default": "False"
    },
    {
      "key": "PUBLIC_SNAPSHOTS",
      "service": "archivebox",
      "description": "Require login to read archived files",
      "secret": false,
      "strategy": "default",
      "default": "False"
    },
    {
      "key": "SEARCH_BACKEND_PORT",
      "service": "archivebox",
      "description": "Sonic channel port",
      "secret": false,
      "strategy": "default",
      "default": "1491"
    },
    {
      "key": "SEARCH_BACKEND_ENGINE",
      "service": "archivebox",
      "description": "Full-text search backend",
      "secret": false,
      "strategy": "default",
      "default": "sonic"
    },
    {
      "key": "SEARCH_BACKEND_PASSWORD",
      "service": "archivebox",
      "description": "Sonic channel password",
      "secret": true,
      "strategy": "railway_provided",
      "railway_source": "reference_variable"
    },
    {
      "key": "SEARCH_BACKEND_HOST_NAME",
      "service": "archivebox",
      "description": "Private hostname of Sonic",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "SONIC_CHANNEL__INET",
      "service": "sonic",
      "description": "Listen on the private network, not loopback",
      "secret": false,
      "strategy": "default",
      "default": "[::]:1491"
    },
    {
      "key": "SONIC_STORE__KV__PATH",
      "service": "sonic",
      "description": "Key-value store on the volume",
      "secret": false,
      "strategy": "default",
      "default": "/var/lib/sonic/store/kv/"
    },
    {
      "key": "SONIC_STORE__FST__PATH",
      "service": "sonic",
      "description": "Word graph on the volume",
      "secret": false,
      "strategy": "default",
      "default": "/var/lib/sonic/store/fst/"
    },
    {
      "key": "SONIC_SERVER__LOG_LEVEL",
      "service": "sonic",
      "description": "Log verbosity",
      "secret": false,
      "strategy": "default",
      "default": "warn"
    },
    {
      "key": "SONIC_CHANNEL__AUTH_PASSWORD",
      "service": "sonic",
      "description": "Sonic channel password",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "SONIC_SEARCH__QUERY_LIMIT_DEFAULT",
      "service": "sonic",
      "description": "Results returned when no limit is given",
      "secret": false,
      "strategy": "default",
      "default": "65535"
    },
    {
      "key": "SONIC_SEARCH__QUERY_LIMIT_MAXIMUM",
      "service": "sonic",
      "description": "Upper bound on result count",
      "secret": false,
      "strategy": "default",
      "default": "65535"
    },
    {
      "key": "SONIC_SEARCH__QUERY_ALTERNATES_TRY",
      "service": "sonic",
      "description": "Alternate word forms tried per query",
      "secret": false,
      "strategy": "default",
      "default": "10"
    },
    {
      "key": "SONIC_STORE__KV__RETAIN_WORD_OBJECTS",
      "service": "sonic",
      "description": "Objects retained per word",
      "secret": false,
      "strategy": "default",
      "default": "100000"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "archivebox-railway"
      }
    },
    "cli": "railway deploy --template archivebox-railway",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "a9a57901-7415-4209-b714-784bcd2a7c3e",
            "serializedConfig": {
              "buckets": {},
              "services": {
                "3abea947-5315-484c-a415-aeb41e1f660d": {
                  "icon": "https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/archivebox.svg",
                  "name": "archivebox",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": "/health/",
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "repo": "https://github.com/gridalpha/archivebox-railway",
                    "rootDirectory": null
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "HTTP port the server binds",
                      "defaultValue": "8000"
                    },
                    "TIMEOUT": {
                      "isOptional": false,
                      "description": "Seconds allowed per extractor",
                      "defaultValue": "120"
                    },
                    "SAVE_MEDIA": {
                      "isOptional": false,
                      "description": "yt-dlp media capture, off by default",
                      "defaultValue": "False"
                    },
                    "SECRET_KEY": {
                      "isOptional": false,
                      "description": "Django session signing key",
                      "defaultValue": "{{SECRET_KEY}}"
                    },
                    "PUBLIC_INDEX": {
                      "isOptional": false,
                      "description": "Hide the snapshot list from anonymous visitors",
                      "defaultValue": "False"
                    },
                    "ADMIN_PASSWORD": {
                      "isOptional": false,
                      "description": "Superuser password, override to choose one",
                      "defaultValue": "{{ADMIN_PASSWORD}}"
                    },
                    "ADMIN_USERNAME": {
                      "isOptional": false,
                      "description": "Superuser created on first boot",
                      "defaultValue": "admin"
                    },
                    "MEDIA_MAX_SIZE": {
                      "isOptional": false,
                      "description": "Per-file media size ceiling",
                      "defaultValue": "250m"
                    },
                    "PUBLIC_ADD_VIEW": {
                      "isOptional": false,
                      "description": "Only logged-in users may submit URLs",
                      "defaultValue": "False"
                    },
                    "PUBLIC_SNAPSHOTS": {
                      "isOptional": false,
                      "description": "Require login to read archived files",
                      "defaultValue": "False"
                    },
                    "SEARCH_BACKEND_PORT": {
                      "isOptional": false,
                      "description": "Sonic channel port",
                      "defaultValue": "1491"
                    },
                    "SEARCH_BACKEND_ENGINE": {
                      "isOptional": false,
                      "description": "Full-text search backend",
                      "defaultValue": "sonic"
                    },
                    "SEARCH_BACKEND_PASSWORD": {
                      "isOptional": false,
                      "description": "Sonic channel password",
                      "defaultValue": "${{sonic.SONIC_CHANNEL__AUTH_PASSWORD}}"
                    },
                    "SEARCH_BACKEND_HOST_NAME": {
                      "isOptional": false,
                      "description": "Private hostname of Sonic",
                      "defaultValue": "${{sonic.RAILWAY_PRIVATE_DOMAIN}}"
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>:8000": {
                        "port": 8000
                      }
                    }
                  },
                  "volumeMounts": {
                    "3abea947-5315-484c-a415-aeb41e1f660d": {
                      "mountPath": "/data"
                    }
                  }
                },
                "ac04e239-1d85-4dcc-bbb1-9d5390839403": {
                  "icon": "https://valeriansaliou.github.io/sonic/images/banner.jpg",
                  "name": "sonic",
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": null,
                    "restartPolicyType": "ALWAYS",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "valeriansaliou/sonic:v1.8.1"
                  },
                  "variables": {
                    "SONIC_CHANNEL__INET": {
                      "isOptional": false,
                      "description": "Listen on the private network, not loopback",
                      "defaultValue": "[::]:1491"
                    },
                    "SONIC_STORE__KV__PATH": {
                      "isOptional": false,
                      "description": "Key-value store on the volume",
                      "defaultValue": "/var/lib/sonic/store/kv/"
                    },
                    "SONIC_STORE__FST__PATH": {
                      "isOptional": false,
                      "description": "Word graph on the volume",
                      "defaultValue": "/var/lib/sonic/store/fst/"
                    },
                    "SONIC_SERVER__LOG_LEVEL": {
                      "isOptional": false,
                      "description": "Log verbosity",
                      "defaultValue": "warn"
                    },
                    "SONIC_CHANNEL__AUTH_PASSWORD": {
                      "isOptional": false,
                      "description": "Sonic channel password",
                      "defaultValue": "{{SONIC_CHANNEL__AUTH_PASSWORD}}"
                    },
                    "SONIC_SEARCH__QUERY_LIMIT_DEFAULT": {
                      "isOptional": false,
                      "description": "Results returned when no limit is given",
                      "defaultValue": "65535"
                    },
                    "SONIC_SEARCH__QUERY_LIMIT_MAXIMUM": {
                      "isOptional": false,
                      "description": "Upper bound on result count",
                      "defaultValue": "65535"
                    },
                    "SONIC_SEARCH__QUERY_ALTERNATES_TRY": {
                      "isOptional": false,
                      "description": "Alternate word forms tried per query",
                      "defaultValue": "10"
                    },
                    "SONIC_STORE__KV__RETAIN_WORD_OBJECTS": {
                      "isOptional": false,
                      "description": "Objects retained per word",
                      "defaultValue": "100000"
                    }
                  },
                  "volumeMounts": {
                    "ac04e239-1d85-4dcc-bbb1-9d5390839403": {
                      "mountPath": "/var/lib/sonic/store"
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {
    "healthcheck": {
      "service": "archivebox",
      "method": "GET",
      "path": "/health/",
      "expect_status": 200
    }
  },
  "resources": {
    "expected_services": 2,
    "needs_volume": true
  },
  "generated_at": "2026-09-21T22:14:44.200Z",
  "generator_version": "0.1.0",
  "status": "validated",
  "validated_at": "2026-09-21T20:22:41.265Z",
  "success_rate_30d": 1,
  "validation": {
    "last_run_id": "run_f66694e982d24e2db7b4",
    "checks": [
      {
        "name": "workflow_completed",
        "passed": true
      },
      {
        "name": "all_services_deployed",
        "passed": true
      },
      {
        "name": "healthcheck",
        "passed": true
      },
      {
        "name": "stays_up",
        "passed": true
      }
    ],
    "typical_ready_seconds": 193,
    "typical_build_seconds": 72,
    "typical_start_seconds": 20,
    "slowest_service": "archivebox"
  }
}
