fix(compose): drop host port binding, add Coolify FQDN hints for Traefik
Removes the postgrest host port (3000:3000) that the README already flagged as local-dev-only. Adds SERVICE_FQDN_POSTGREST_3000 / SERVICE_FQDN_TRIPS_WEB_8080 environment hints so Coolify auto-wires Traefik routing to the correct container ports when this stack is deployed as a Docker Compose resource. Local dev: re-add ports via a gitignored compose/docker-compose.override.yaml. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
parent
b0db22c669
commit
98bedaae5f
1 changed files with 10 additions and 7 deletions
|
|
@ -15,11 +15,11 @@ services:
|
|||
PGRST_DB_MAX_ROWS: "10000"
|
||||
PGRST_OPENAPI_SERVER_PROXY_URI: ${PGRST_PUBLIC_URL:-http://localhost:3000}
|
||||
PGRST_SERVER_CORS_ALLOWED_ORIGINS: ${TRIPS_WEB_URL:-http://localhost:5173}
|
||||
# Local-dev convenience: bind to host port 3000 so the React dev server
|
||||
# can hit it without going through Caddy. Coolify deployments should
|
||||
# remove this and route via the platform's reverse proxy instead.
|
||||
ports:
|
||||
- "3000:3000"
|
||||
# Coolify magic: triggers FQDN assignment + Traefik routing to port 3000.
|
||||
# Set the actual FQDN in the Coolify resource's Domains panel.
|
||||
SERVICE_FQDN_POSTGREST_3000: ${PGRST_PUBLIC_URL}
|
||||
# No host port binding for Coolify. For local dev, drop a
|
||||
# compose/docker-compose.override.yaml that re-adds: ports: ["3000:3000"].
|
||||
|
||||
trips_web:
|
||||
build:
|
||||
|
|
@ -31,7 +31,10 @@ services:
|
|||
restart: always
|
||||
expose:
|
||||
- "8080"
|
||||
environment:
|
||||
# Coolify magic: triggers FQDN assignment + Traefik routing to port 8080.
|
||||
# Set the actual FQDN in the Coolify resource's Domains panel.
|
||||
SERVICE_FQDN_TRIPS_WEB_8080: ${TRIPS_WEB_URL}
|
||||
depends_on:
|
||||
- postgrest
|
||||
# No host port binding for production. For local dev, prefer running
|
||||
# `pnpm dev` directly against the postgrest service above.
|
||||
# For local dev, prefer running `pnpm dev` directly against postgrest.
|
||||
|
|
|
|||
Loading…
Reference in a new issue