This commit is contained in:
+36
-3
@@ -9,6 +9,39 @@ services:
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
- "8080:80"
|
||||
# Optionnel: si vous avez des logos dans un dossier externe sur votre machine hôte
|
||||
# volumes:
|
||||
# - ./games-assets:/usr/share/nginx/html/games-assets
|
||||
depends_on:
|
||||
- backend
|
||||
|
||||
backend:
|
||||
build:
|
||||
context: ./server
|
||||
dockerfile: Dockerfile
|
||||
container_name: skori-backend
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
NODE_ENV: production
|
||||
PORT: 3001
|
||||
DATABASE_URL: postgres://skori:${POSTGRES_PASSWORD:-skori}@postgres:5432/skori
|
||||
JWT_SECRET: ${JWT_SECRET:-change-me-in-production}
|
||||
depends_on:
|
||||
postgres:
|
||||
condition: service_healthy
|
||||
|
||||
postgres:
|
||||
image: postgres:16-alpine
|
||||
container_name: skori-postgres
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
POSTGRES_USER: skori
|
||||
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-skori}
|
||||
POSTGRES_DB: skori
|
||||
volumes:
|
||||
- skori-pgdata:/var/lib/postgresql/data
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "pg_isready -U skori -d skori"]
|
||||
interval: 5s
|
||||
timeout: 5s
|
||||
retries: 10
|
||||
|
||||
volumes:
|
||||
skori-pgdata:
|
||||
|
||||
Reference in New Issue
Block a user