remote pg for prod
This commit is contained in:
parent
9537c0342c
commit
542202883c
@ -15,15 +15,12 @@ services:
|
||||
- ADMIN_PASSWORD
|
||||
- COOKIE_SECRET
|
||||
- NODE_ENV=production
|
||||
depends_on:
|
||||
postgres:
|
||||
condition: service_healthy
|
||||
healthcheck:
|
||||
test: ["CMD", "sh", "-c", "[ -f /app/dist/index.html ] && wget -qO- http://localhost:3000/api/health || exit 1"]
|
||||
interval: 10s
|
||||
timeout: 5s
|
||||
retries: 30
|
||||
start_period: 60s
|
||||
retries: 60
|
||||
start_period: 120s
|
||||
restart: unless-stopped
|
||||
labels:
|
||||
- traefik.enable=true
|
||||
@ -34,21 +31,6 @@ services:
|
||||
- traefik.http.services.api.loadbalancer.server.port=3000
|
||||
- traefik.http.routers.api.priority=2
|
||||
|
||||
postgres:
|
||||
image: postgres:16-alpine
|
||||
volumes:
|
||||
- pgdata:/var/lib/postgresql/data
|
||||
environment:
|
||||
- POSTGRES_DB=rebours
|
||||
- POSTGRES_USER=rebours
|
||||
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "pg_isready -U rebours -d rebours"]
|
||||
interval: 5s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
restart: unless-stopped
|
||||
|
||||
nginx:
|
||||
image: nginx:alpine
|
||||
volumes:
|
||||
@ -69,4 +51,3 @@ services:
|
||||
|
||||
volumes:
|
||||
static:
|
||||
pgdata:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user