🚀 Patch auto

This commit is contained in:
karim hassan
2025-08-24 23:00:40 +00:00
parent 92e6afff00
commit f1103d67a0
1314 changed files with 2511 additions and 562 deletions

View File

@@ -1,45 +1,44 @@
services:
db:
image: postgres:16-alpine
image: postgres:16
container_name: supersunday_db
environment:
POSTGRES_DB: ${POSTGRES_DB:-supersunday}
POSTGRES_USER: ${POSTGRES_USER:-supersunday}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-supersunday}
POSTGRES_PASSWORD: postgres
POSTGRES_DB: supersunday
volumes:
- db_data:/var/lib/postgresql/data
- ./db/init:/docker-entrypoint-initdb.d:ro
- ./data/db:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER:-supersunday} -d ${POSTGRES_DB:-supersunday}"]
test: ["CMD-SHELL", "pg_isready -U postgres -d supersunday -h localhost"]
interval: 5s
timeout: 5s
timeout: 3s
retries: 20
start_period: 10s
api:
build: ./backend
env_file: .env
container_name: supersunday_api
env_file:
- ./backend/.env
depends_on:
db:
condition: service_healthy
expose:
- "8080"
- "4000"
healthcheck:
test: ["CMD", "wget", "-qO-", "http://localhost:8080/api/health"]
test: ["CMD-SHELL", "curl -fsS http://localhost:4000/api/health || exit 1"]
interval: 10s
timeout: 5s
retries: 20
timeout: 3s
retries: 12
start_period: 30s
web:
build: ./frontend
image: nginx:alpine
container_name: supersunday_web
depends_on:
api:
condition: service_healthy
ports:
- "80:80"
healthcheck:
test: ["CMD-SHELL", "wget -qO- http://localhost/health || exit 1"]
interval: 10s
timeout: 5s
retries: 20
volumes:
db_data:
- "80:80" # Tout le trafic arrive sur Nginx
volumes:
- ./frontend/public:/usr/share/nginx/html:ro
- ./nginx/nginx.conf:/etc/nginx/nginx.conf:ro