fix: match container ports to host ports
This commit is contained in:
@@ -12,9 +12,9 @@ The deployment model is expected to follow the shared dev, QA, and production br
|
|||||||
|
|
||||||
## Port Mapping
|
## Port Mapping
|
||||||
|
|
||||||
- Dev: host port `7003` -> container port `3000`
|
- Dev: host port `7003` -> container port `7003`
|
||||||
- QA: host port `6003` -> container port `3000`
|
- QA: host port `6003` -> container port `6003`
|
||||||
- Production: host port `5003` -> container port `3000`
|
- Production: host port `5003` -> container port `5003`
|
||||||
|
|
||||||
## Health Check
|
## Health Check
|
||||||
|
|
||||||
|
|||||||
@@ -27,6 +27,7 @@ Phase 1 scaffold started from the approved planning docs.
|
|||||||
- Prisma schema
|
- Prisma schema
|
||||||
- Health endpoint
|
- Health endpoint
|
||||||
- Environment ports aligned to `7003`, `6003`, and `5003` for dev, QA, and production
|
- Environment ports aligned to `7003`, `6003`, and `5003` for dev, QA, and production
|
||||||
|
- Container and host ports match for each environment
|
||||||
|
|
||||||
## Next Build Step
|
## Next Build Step
|
||||||
|
|
||||||
|
|||||||
@@ -6,6 +6,7 @@ services:
|
|||||||
- /app/node_modules
|
- /app/node_modules
|
||||||
environment:
|
environment:
|
||||||
NODE_ENV: development
|
NODE_ENV: development
|
||||||
|
PORT: 7003
|
||||||
NEXT_PUBLIC_SITE_URL: http://localhost:3000
|
NEXT_PUBLIC_SITE_URL: http://localhost:3000
|
||||||
ports:
|
ports:
|
||||||
- "${WEB_PORT:-7003}:3000"
|
- "7003:7003"
|
||||||
|
|||||||
@@ -2,6 +2,7 @@ services:
|
|||||||
web:
|
web:
|
||||||
environment:
|
environment:
|
||||||
NODE_ENV: production
|
NODE_ENV: production
|
||||||
|
PORT: 5003
|
||||||
NEXT_PUBLIC_SITE_URL: ${NEXT_PUBLIC_SITE_URL:-https://example.com}
|
NEXT_PUBLIC_SITE_URL: ${NEXT_PUBLIC_SITE_URL:-https://example.com}
|
||||||
ports:
|
ports:
|
||||||
- "${WEB_PORT:-5003}:3000"
|
- "5003:5003"
|
||||||
|
|||||||
@@ -2,6 +2,7 @@ services:
|
|||||||
web:
|
web:
|
||||||
environment:
|
environment:
|
||||||
NODE_ENV: production
|
NODE_ENV: production
|
||||||
|
PORT: 6003
|
||||||
NEXT_PUBLIC_SITE_URL: ${NEXT_PUBLIC_SITE_URL:-http://localhost:3001}
|
NEXT_PUBLIC_SITE_URL: ${NEXT_PUBLIC_SITE_URL:-http://localhost:3001}
|
||||||
ports:
|
ports:
|
||||||
- "${WEB_PORT:-6003}:3000"
|
- "6003:6003"
|
||||||
|
|||||||
@@ -5,13 +5,14 @@ services:
|
|||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
environment:
|
environment:
|
||||||
NODE_ENV: production
|
NODE_ENV: production
|
||||||
|
PORT: ${PORT:-3000}
|
||||||
NEXT_PUBLIC_SITE_URL: ${NEXT_PUBLIC_SITE_URL:-http://localhost:3000}
|
NEXT_PUBLIC_SITE_URL: ${NEXT_PUBLIC_SITE_URL:-http://localhost:3000}
|
||||||
DATABASE_URL: ${DATABASE_URL:-postgresql://postgres:postgres@db:5432/holiday_property_booking?schema=public}
|
DATABASE_URL: ${DATABASE_URL:-postgresql://postgres:postgres@db:5432/holiday_property_booking?schema=public}
|
||||||
depends_on:
|
depends_on:
|
||||||
db:
|
db:
|
||||||
condition: service_healthy
|
condition: service_healthy
|
||||||
ports:
|
ports:
|
||||||
- "${WEB_PORT:-3000}:3000"
|
- "${PORT:-3000}:${PORT:-3000}"
|
||||||
|
|
||||||
db:
|
db:
|
||||||
image: postgres:16-alpine
|
image: postgres:16-alpine
|
||||||
@@ -26,4 +27,3 @@ services:
|
|||||||
interval: 5s
|
interval: 5s
|
||||||
timeout: 5s
|
timeout: 5s
|
||||||
retries: 10
|
retries: 10
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user