From 342a389f3d94a20db2b1b0e52182d27fd3fed6a0 Mon Sep 17 00:00:00 2001 From: kisfenyo Date: Mon, 29 Jun 2026 13:42:15 +0200 Subject: [PATCH] calcom: add DATABASE_DIRECT_URL (required by Prisma; migrations failed without it) Cal.com's prisma schema declares directUrl=env(DATABASE_DIRECT_URL); without it the startup 'prisma migrate deploy' fails (P1012) and the schema stays incomplete -> the app 500s. Set to the same direct Postgres URL. Pre-existing, never caught (bad image pin meant calcom never deployed). Co-Authored-By: Claude Opus 4.8 (1M context) --- templates/calcom/docker-compose.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/templates/calcom/docker-compose.yml b/templates/calcom/docker-compose.yml index d4ab28d..0a8dbca 100644 --- a/templates/calcom/docker-compose.yml +++ b/templates/calcom/docker-compose.yml @@ -21,6 +21,9 @@ services: - NEXTAUTH_SECRET=${NEXTAUTH_SECRET} - CALENDSO_ENCRYPTION_KEY=${CALENDSO_ENCRYPTION_KEY} - DATABASE_URL=postgresql://calcom:${DB_PASSWORD}@calcom-postgres:5432/calcom + # Cal.com's Prisma schema requires directUrl too; without it `prisma migrate deploy` fails on + # startup and the DB schema stays incomplete (500s on /api/health). Same direct Postgres URL. + - DATABASE_DIRECT_URL=postgresql://calcom:${DB_PASSWORD}@calcom-postgres:5432/calcom - NEXT_PUBLIC_WEBAPP_URL=https://${SUBDOMAIN}.${DOMAIN} - NEXTAUTH_URL=https://${SUBDOMAIN}.${DOMAIN} # App-email (managed relay). Injected by the controller only when app-email is on (global + per-app);