Skip to content

Commit 58bd1ba

Browse files
committed
fix(compose): derive realtime BETTER_AUTH_URL from NEXT_PUBLIC_APP_URL
realtime read BETTER_AUTH_URL directly and fell back to localhost while simstudio derived it from NEXT_PUBLIC_APP_URL, so setting only the public origin left realtime authenticating against http://localhost:3000.
1 parent ee8dc28 commit 58bd1ba

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

docker-compose.prod.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,9 @@ services:
8181
- NODE_ENV=production
8282
- DATABASE_URL=postgresql://${POSTGRES_USER:-postgres}:${POSTGRES_PASSWORD:-postgres}@db:5432/${POSTGRES_DB:-simstudio}
8383
- NEXT_PUBLIC_APP_URL=${NEXT_PUBLIC_APP_URL:-http://localhost:3000}
84-
- BETTER_AUTH_URL=${BETTER_AUTH_URL:-http://localhost:3000}
84+
# Derived from NEXT_PUBLIC_APP_URL, matching the simstudio service — a
85+
# single public-origin variable keeps the two from disagreeing.
86+
- BETTER_AUTH_URL=${NEXT_PUBLIC_APP_URL:-http://localhost:3000}
8587
- 'BETTER_AUTH_SECRET=${BETTER_AUTH_SECRET:?is required and must match the value used by the simstudio service}'
8688
- 'INTERNAL_API_SECRET=${INTERNAL_API_SECRET:?is required and must match the value used by the simstudio service}'
8789
- REDIS_URL=${REDIS_URL:-redis://redis:6379}

0 commit comments

Comments
 (0)