231 lines
6.9 KiB
YAML
231 lines
6.9 KiB
YAML
version: '3.9'
|
|
|
|
services:
|
|
postgres:
|
|
image: postgres:16-alpine
|
|
restart: unless-stopped
|
|
environment:
|
|
POSTGRES_USER: nxtgauge
|
|
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-nxtgauge_dev}
|
|
POSTGRES_DB: nxtgauge_db
|
|
ports:
|
|
- '5432:5432'
|
|
volumes:
|
|
- pgdata:/var/lib/postgresql/data
|
|
healthcheck:
|
|
test: ['CMD-SHELL', 'pg_isready -U nxtgauge -d nxtgauge_db']
|
|
interval: 5s
|
|
timeout: 5s
|
|
retries: 10
|
|
|
|
# ── Core Services ────────────────────────────────────────────────────────
|
|
|
|
gateway:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/gateway/Dockerfile
|
|
environment:
|
|
PORT: 8000
|
|
USERS_SERVICE_URL: http://users:8080
|
|
COMPANIES_SERVICE_URL: http://companies:8081
|
|
JOB_SEEKERS_SERVICE_URL: http://job_seekers:8082
|
|
CUSTOMERS_SERVICE_URL: http://customers:8083
|
|
PHOTOGRAPHERS_SERVICE_URL: http://photographers:8085
|
|
MAKEUP_ARTISTS_SERVICE_URL: http://makeup_artists:8086
|
|
TUTORS_SERVICE_URL: http://tutors:8087
|
|
DEVELOPERS_SERVICE_URL: http://developers:8088
|
|
VIDEO_EDITORS_SERVICE_URL: http://video_editors:8089
|
|
GRAPHIC_DESIGNERS_SERVICE_URL: http://graphic_designers:8090
|
|
SOCIAL_MEDIA_MANAGERS_SERVICE_URL: http://social_media_managers:8091
|
|
FITNESS_TRAINERS_SERVICE_URL: http://fitness_trainers:8092
|
|
CATERING_SERVICES_SERVICE_URL: http://catering_services:8093
|
|
PAYMENTS_SERVICE_URL: http://payments:8094
|
|
ports:
|
|
- '8000:8000'
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
|
|
users:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/users/Dockerfile
|
|
environment:
|
|
PORT: 8080
|
|
DATABASE_URL: postgresql://nxtgauge:${POSTGRES_PASSWORD:-nxtgauge_dev}@postgres:5432/nxtgauge_db
|
|
JWT_SECRET: ${JWT_SECRET}
|
|
JWT_EXPIRY_MINUTES: 15
|
|
REFRESH_TOKEN_EXPIRY_DAYS: 30
|
|
FRONTEND_URL: ${FRONTEND_URL:-http://localhost:3000}
|
|
SMTP_HOST: ${SMTP_HOST:-}
|
|
SMTP_PORT: ${SMTP_PORT:-587}
|
|
SMTP_USER: ${SMTP_USER:-}
|
|
SMTP_PASS: ${SMTP_PASS:-}
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
|
|
companies:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/companies/Dockerfile
|
|
environment:
|
|
PORT: 8081
|
|
DATABASE_URL: postgresql://nxtgauge:${POSTGRES_PASSWORD:-nxtgauge_dev}@postgres:5432/nxtgauge_db
|
|
JWT_SECRET: ${JWT_SECRET}
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
|
|
job_seekers:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/job_seekers/Dockerfile
|
|
environment:
|
|
PORT: 8082
|
|
DATABASE_URL: postgresql://nxtgauge:${POSTGRES_PASSWORD:-nxtgauge_dev}@postgres:5432/nxtgauge_db
|
|
JWT_SECRET: ${JWT_SECRET}
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
|
|
customers:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/customers/Dockerfile
|
|
environment:
|
|
PORT: 8083
|
|
DATABASE_URL: postgresql://nxtgauge:${POSTGRES_PASSWORD:-nxtgauge_dev}@postgres:5432/nxtgauge_db
|
|
JWT_SECRET: ${JWT_SECRET}
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
|
|
# ── 9 Profession Services ─────────────────────────────────────────────────
|
|
|
|
photographers:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/photographers/Dockerfile
|
|
environment:
|
|
PORT: 8085
|
|
DATABASE_URL: postgresql://nxtgauge:${POSTGRES_PASSWORD:-nxtgauge_dev}@postgres:5432/nxtgauge_db
|
|
JWT_SECRET: ${JWT_SECRET}
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
|
|
makeup_artists:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/makeup_artists/Dockerfile
|
|
environment:
|
|
PORT: 8086
|
|
DATABASE_URL: postgresql://nxtgauge:${POSTGRES_PASSWORD:-nxtgauge_dev}@postgres:5432/nxtgauge_db
|
|
JWT_SECRET: ${JWT_SECRET}
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
|
|
tutors:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/tutors/Dockerfile
|
|
environment:
|
|
PORT: 8087
|
|
DATABASE_URL: postgresql://nxtgauge:${POSTGRES_PASSWORD:-nxtgauge_dev}@postgres:5432/nxtgauge_db
|
|
JWT_SECRET: ${JWT_SECRET}
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
|
|
developers:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/developers/Dockerfile
|
|
environment:
|
|
PORT: 8088
|
|
DATABASE_URL: postgresql://nxtgauge:${POSTGRES_PASSWORD:-nxtgauge_dev}@postgres:5432/nxtgauge_db
|
|
JWT_SECRET: ${JWT_SECRET}
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
|
|
video_editors:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/video_editors/Dockerfile
|
|
environment:
|
|
PORT: 8089
|
|
DATABASE_URL: postgresql://nxtgauge:${POSTGRES_PASSWORD:-nxtgauge_dev}@postgres:5432/nxtgauge_db
|
|
JWT_SECRET: ${JWT_SECRET}
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
|
|
graphic_designers:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/graphic_designers/Dockerfile
|
|
environment:
|
|
PORT: 8090
|
|
DATABASE_URL: postgresql://nxtgauge:${POSTGRES_PASSWORD:-nxtgauge_dev}@postgres:5432/nxtgauge_db
|
|
JWT_SECRET: ${JWT_SECRET}
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
|
|
social_media_managers:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/social_media_managers/Dockerfile
|
|
environment:
|
|
PORT: 8091
|
|
DATABASE_URL: postgresql://nxtgauge:${POSTGRES_PASSWORD:-nxtgauge_dev}@postgres:5432/nxtgauge_db
|
|
JWT_SECRET: ${JWT_SECRET}
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
|
|
fitness_trainers:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/fitness_trainers/Dockerfile
|
|
environment:
|
|
PORT: 8092
|
|
DATABASE_URL: postgresql://nxtgauge:${POSTGRES_PASSWORD:-nxtgauge_dev}@postgres:5432/nxtgauge_db
|
|
JWT_SECRET: ${JWT_SECRET}
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
|
|
catering_services:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/catering_services/Dockerfile
|
|
environment:
|
|
PORT: 8093
|
|
DATABASE_URL: postgresql://nxtgauge:${POSTGRES_PASSWORD:-nxtgauge_dev}@postgres:5432/nxtgauge_db
|
|
JWT_SECRET: ${JWT_SECRET}
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
|
|
# ── Payments ──────────────────────────────────────────────────────────────
|
|
|
|
payments:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/payments/Dockerfile
|
|
environment:
|
|
PORT: 8094
|
|
DATABASE_URL: postgresql://nxtgauge:${POSTGRES_PASSWORD:-nxtgauge_dev}@postgres:5432/nxtgauge_db
|
|
JWT_SECRET: ${JWT_SECRET}
|
|
RAZORPAY_KEY_ID: ${RAZORPAY_KEY_ID:-}
|
|
RAZORPAY_KEY_SECRET: ${RAZORPAY_KEY_SECRET:-}
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
|
|
volumes:
|
|
pgdata:
|