services: postgres: image: postgres:16-alpine container_name: light-toir-v2-postgres restart: unless-stopped environment: POSTGRES_DB: light-toir-v2 POSTGRES_USER: ${DB_USER} POSTGRES_PASSWORD: ${DB_PASSWORD} volumes: - postgres_data:/var/lib/postgresql/data networks: - internal backend: build: context: ./backend dockerfile: Dockerfile container_name: light-toir-v2-backend restart: unless-stopped depends_on: - postgres environment: DATABASE_URL: postgresql://${DB_USER}:${DB_PASSWORD}@postgres:5432/light-toir-v2 KEYCLOAK_URL: ${KEYCLOAK_URL} NODE_ENV: production networks: - internal frontend: build: context: ./frontend dockerfile: Dockerfile container_name: light-toir-v2-frontend restart: unless-stopped networks: - internal nginx: build: context: ./nginx dockerfile: Dockerfile container_name: light-toir-v2-nginx restart: unless-stopped depends_on: - backend - frontend networks: - internal - proxy volumes: postgres_data: networks: internal: proxy: external: true