{
  "manifest_version": "1.0.0",
  "template": {
    "id": "dcbe1107-0b83-4555-8dae-9ce15a149650",
    "slug": "calcom-production",
    "name": "Cal.com | Open-Source Calendly Alternative with Postgres",
    "description": "Self-hosted scheduling: booking pages, calendar sync and event types",
    "url": "https://railway.com/deploy/calcom-production",
    "upstream": {
      "image": "calcom/cal.com:v6.2.0"
    }
  },
  "services": [
    {
      "name": "Postgres",
      "source": {
        "image": "postgres:17.11-alpine"
      },
      "needs_volume": true,
      "volume_mount_path": "/var/lib/postgresql/data",
      "http": false
    },
    {
      "name": "Cal.com",
      "source": {
        "image": "calcom/cal.com:v6.2.0"
      },
      "needs_volume": false,
      "http": true
    }
  ],
  "required_inputs": [
    {
      "key": "PGDATA",
      "service": "Postgres",
      "description": "Data subdirectory - keeps Postgres happy on Railway volumes",
      "secret": false,
      "strategy": "default",
      "default": "/var/lib/postgresql/data/pgdata"
    },
    {
      "key": "POSTGRES_DB",
      "service": "Postgres",
      "description": "Database name",
      "secret": false,
      "strategy": "default",
      "default": "calcom"
    },
    {
      "key": "POSTGRES_USER",
      "service": "Postgres",
      "description": "Database user",
      "secret": false,
      "strategy": "default",
      "default": "calcom"
    },
    {
      "key": "POSTGRES_PASSWORD",
      "service": "Postgres",
      "description": "Auto-generated database password",
      "secret": true,
      "strategy": "generate",
      "generate": "strong_password"
    },
    {
      "key": "RAILWAY_DEPLOYMENT_DRAINING_SECONDS",
      "service": "Postgres",
      "description": "Time for Postgres to shut down cleanly on redeploy",
      "secret": false,
      "strategy": "default",
      "default": "60"
    },
    {
      "key": "PORT",
      "service": "Cal.com",
      "description": "Port Cal.com listens on - leave as is",
      "secret": false,
      "strategy": "default",
      "default": "3000"
    },
    {
      "key": "HOSTNAME",
      "service": "Cal.com",
      "description": "Listen on IPv6 and IPv4 so Railway's private network can reach it",
      "secret": false,
      "strategy": "default",
      "default": "::"
    },
    {
      "key": "DATABASE_URL",
      "service": "Cal.com",
      "description": "Postgres on the private network",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "NEXTAUTH_URL",
      "service": "Cal.com",
      "description": "Sign-in base URL - keep it equal to NEXT_PUBLIC_WEBAPP_URL",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "DATABASE_HOST",
      "service": "Cal.com",
      "description": "host:port the start command waits for before migrating",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "EMAIL_FROM_NAME",
      "service": "Cal.com",
      "description": "Sender name for emails",
      "secret": false,
      "strategy": "default",
      "default": "Cal.com"
    },
    {
      "key": "NEXTAUTH_SECRET",
      "service": "Cal.com",
      "description": "Signs login sessions - changing it logs everyone out",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "EMAIL_SERVER_PORT",
      "service": "Cal.com",
      "description": "SMTP port (465 implicit TLS, 587 STARTTLS)",
      "secret": false,
      "strategy": "default",
      "default": "465"
    },
    {
      "key": "DATABASE_DIRECT_URL",
      "service": "Cal.com",
      "description": "Postgres for migrations (same database)",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_private_domain"
    },
    {
      "key": "GOOGLE_LOGIN_ENABLED",
      "service": "Cal.com",
      "description": "Set to true to show Sign in with Google (needs GOOGLE_API_CREDENTIALS)",
      "secret": false,
      "strategy": "default",
      "default": "false"
    },
    {
      "key": "NEXT_PUBLIC_WEBAPP_URL",
      "service": "Cal.com",
      "description": "Public URL of Cal.com (booking links, emails, OAuth callbacks). Rewritten into the built app on every boot - set it to your custom domain after adding one",
      "secret": false,
      "strategy": "railway_provided",
      "railway_source": "railway_domain"
    },
    {
      "key": "CALENDSO_ENCRYPTION_KEY",
      "service": "Cal.com",
      "description": "Encrypts stored calendar and app credentials (exactly 32 characters). BACK IT UP - changing it breaks every connected calendar",
      "secret": true,
      "strategy": "generate",
      "generate": "random_base64_32"
    },
    {
      "key": "CALCOM_TELEMETRY_DISABLED",
      "service": "Cal.com",
      "description": "Turn off Cal.com's anonymous usage telemetry",
      "secret": false,
      "strategy": "default",
      "default": "1"
    },
    {
      "key": "RAILWAY_HEALTHCHECK_TIMEOUT_SEC",
      "service": "Cal.com",
      "description": "First boot applies ~590 database migrations and seeds the app store before the health check can pass",
      "secret": false,
      "strategy": "default",
      "default": "600"
    }
  ],
  "deploy": {
    "mcp": {
      "server": "railway",
      "tool": "deploy_template",
      "args": {
        "template_code": "calcom-production"
      }
    },
    "cli": "railway deploy --template calcom-production",
    "api": {
      "method": "POST",
      "path": "/graphql/v2",
      "body": {
        "query": "mutation templateDeploy($input: TemplateDeployV2Input!) { templateDeployV2(input: $input) { projectId workflowId } }",
        "variables": {
          "input": {
            "templateId": "dcbe1107-0b83-4555-8dae-9ce15a149650",
            "serializedConfig": {
              "services": {
                "55066bad-9ed0-4327-8ca3-fa2f02742bc2": {
                  "icon": "https://devicons.railway.app/i/postgresql.svg",
                  "name": "Postgres",
                  "build": {},
                  "deploy": {
                    "startCommand": null,
                    "healthcheckPath": null,
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "postgres:17.11-alpine"
                  },
                  "variables": {
                    "PGDATA": {
                      "isOptional": false,
                      "description": "Data subdirectory - keeps Postgres happy on Railway volumes",
                      "defaultValue": "/var/lib/postgresql/data/pgdata"
                    },
                    "POSTGRES_DB": {
                      "isOptional": false,
                      "description": "Database name",
                      "defaultValue": "calcom"
                    },
                    "POSTGRES_USER": {
                      "isOptional": false,
                      "description": "Database user",
                      "defaultValue": "calcom"
                    },
                    "POSTGRES_PASSWORD": {
                      "isOptional": false,
                      "description": "Auto-generated database password",
                      "defaultValue": "{{POSTGRES_PASSWORD}}"
                    },
                    "RAILWAY_DEPLOYMENT_DRAINING_SECONDS": {
                      "isOptional": false,
                      "description": "Time for Postgres to shut down cleanly on redeploy",
                      "defaultValue": "60"
                    }
                  },
                  "networking": {
                    "serviceDomains": {}
                  },
                  "volumeMounts": {
                    "c0328cea-aad6-4075-9009-e160556fccaa": {
                      "mountPath": "/var/lib/postgresql/data"
                    }
                  }
                },
                "9299fc23-fb4d-4566-9d05-691fbcd9eaa2": {
                  "icon": "https://raw.githubusercontent.com/nomideusz/calcom-railway/main/icon.svg",
                  "name": "Cal.com",
                  "build": {},
                  "deploy": {
                    "startCommand": "/bin/sh -c \"scripts/replace-placeholder.sh $BUILT_NEXT_PUBLIC_WEBAPP_URL $NEXT_PUBLIC_WEBAPP_URL && scripts/wait-for-it.sh $DATABASE_HOST -t 120 -- true && npx prisma migrate deploy --schema packages/prisma/schema.prisma && npx ts-node --transpile-only scripts/seed-app-store.ts && cd apps/web && exec /calcom/node_modules/.bin/next start\"",
                    "healthcheckPath": "/api/auth/session",
                    "restartPolicyType": "ON_FAILURE",
                    "restartPolicyMaxRetries": 10
                  },
                  "source": {
                    "image": "calcom/cal.com:v6.2.0"
                  },
                  "variables": {
                    "PORT": {
                      "isOptional": false,
                      "description": "Port Cal.com listens on - leave as is",
                      "defaultValue": "3000"
                    },
                    "HOSTNAME": {
                      "isOptional": false,
                      "description": "Listen on IPv6 and IPv4 so Railway's private network can reach it",
                      "defaultValue": "::"
                    },
                    "EMAIL_FROM": {
                      "isOptional": true,
                      "description": "Optional sender address for booking confirmations and reminders, e.g. cal@example.com (Railway allows outbound SMTP on Pro only)",
                      "defaultValue": ""
                    },
                    "DATABASE_URL": {
                      "isOptional": false,
                      "description": "Postgres on the private network",
                      "defaultValue": "postgresql://${{Postgres.POSTGRES_USER}}:${{Postgres.POSTGRES_PASSWORD}}@${{Postgres.RAILWAY_PRIVATE_DOMAIN}}:5432/${{Postgres.POSTGRES_DB}}"
                    },
                    "NEXTAUTH_URL": {
                      "isOptional": false,
                      "description": "Sign-in base URL - keep it equal to NEXT_PUBLIC_WEBAPP_URL",
                      "defaultValue": "https://${{RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "DATABASE_HOST": {
                      "isOptional": false,
                      "description": "host:port the start command waits for before migrating",
                      "defaultValue": "${{Postgres.RAILWAY_PRIVATE_DOMAIN}}:5432"
                    },
                    "EMAIL_FROM_NAME": {
                      "isOptional": true,
                      "description": "Sender name for emails",
                      "defaultValue": "Cal.com"
                    },
                    "NEXTAUTH_SECRET": {
                      "isOptional": false,
                      "description": "Signs login sessions - changing it logs everyone out",
                      "defaultValue": "{{NEXTAUTH_SECRET}}"
                    },
                    "EMAIL_SERVER_HOST": {
                      "isOptional": true,
                      "description": "SMTP server",
                      "defaultValue": ""
                    },
                    "EMAIL_SERVER_PORT": {
                      "isOptional": true,
                      "description": "SMTP port (465 implicit TLS, 587 STARTTLS)",
                      "defaultValue": "465"
                    },
                    "EMAIL_SERVER_USER": {
                      "isOptional": true,
                      "description": "SMTP username",
                      "defaultValue": ""
                    },
                    "CALCOM_LICENSE_KEY": {
                      "isOptional": true,
                      "description": "Optional Cal.com commercial license key for enterprise features (teams, workflows, insights). Leave empty for the AGPL edition",
                      "defaultValue": ""
                    },
                    "DATABASE_DIRECT_URL": {
                      "isOptional": false,
                      "description": "Postgres for migrations (same database)",
                      "defaultValue": "postgresql://${{Postgres.POSTGRES_USER}}:${{Postgres.POSTGRES_PASSWORD}}@${{Postgres.RAILWAY_PRIVATE_DOMAIN}}:5432/${{Postgres.POSTGRES_DB}}"
                    },
                    "GOOGLE_LOGIN_ENABLED": {
                      "isOptional": true,
                      "description": "Set to true to show Sign in with Google (needs GOOGLE_API_CREDENTIALS)",
                      "defaultValue": "false"
                    },
                    "EMAIL_SERVER_PASSWORD": {
                      "isOptional": true,
                      "description": "SMTP password",
                      "defaultValue": ""
                    },
                    "GOOGLE_API_CREDENTIALS": {
                      "isOptional": true,
                      "description": "Optional Google OAuth client JSON for Google Calendar and Meet, e.g. {\"web\":{\"client_id\":\"...\",\"client_secret\":\"...\",\"redirect_uris\":[\"https://YOUR-DOMAIN/api/integrations/googlecalendar/callback\",\"https://YOUR-DOMAIN/api/auth/callback/google\"]}}",
                      "defaultValue": ""
                    },
                    "NEXT_PUBLIC_WEBAPP_URL": {
                      "isOptional": false,
                      "description": "Public URL of Cal.com (booking links, emails, OAuth callbacks). Rewritten into the built app on every boot - set it to your custom domain after adding one",
                      "defaultValue": "https://${{RAILWAY_PUBLIC_DOMAIN}}"
                    },
                    "CALENDSO_ENCRYPTION_KEY": {
                      "isOptional": false,
                      "description": "Encrypts stored calendar and app credentials (exactly 32 characters). BACK IT UP - changing it breaks every connected calendar",
                      "defaultValue": "{{CALENDSO_ENCRYPTION_KEY}}"
                    },
                    "CALCOM_TELEMETRY_DISABLED": {
                      "isOptional": false,
                      "description": "Turn off Cal.com's anonymous usage telemetry",
                      "defaultValue": "1"
                    },
                    "RAILWAY_HEALTHCHECK_TIMEOUT_SEC": {
                      "isOptional": false,
                      "description": "First boot applies ~590 database migrations and seeds the app store before the health check can pass",
                      "defaultValue": "600"
                    }
                  },
                  "networking": {
                    "serviceDomains": {
                      "<hasDomain>": {}
                    }
                  },
                  "volumeMounts": {}
                }
              }
            }
          }
        }
      }
    }
  },
  "post_deploy": {
    "healthcheck": {
      "service": "Cal.com",
      "method": "GET",
      "path": "/api/auth/session",
      "expect_status": 200
    }
  },
  "resources": {
    "expected_services": 2,
    "needs_volume": true
  },
  "generated_at": "2026-10-12T04:14:37.344Z",
  "generator_version": "0.1.0",
  "status": "validated",
  "validated_at": "2026-10-12T03:34:52.092Z",
  "success_rate_30d": 1,
  "validation": {
    "last_run_id": "run_2ac29fcd64664b30bca7",
    "checks": [
      {
        "name": "workflow_completed",
        "passed": true
      },
      {
        "name": "all_services_deployed",
        "passed": true
      },
      {
        "name": "healthcheck",
        "passed": true
      },
      {
        "name": "stays_up",
        "passed": true
      }
    ],
    "typical_ready_seconds": 88,
    "typical_build_seconds": 0,
    "typical_start_seconds": 71,
    "slowest_service": "Cal.com"
  }
}
