All checks were successful
Build and Publish Images / build-and-push (push) Successful in 10s
52 lines
1.2 KiB
YAML
52 lines
1.2 KiB
YAML
services:
|
|
db:
|
|
image: postgres:17-alpine
|
|
container_name: wedding_db
|
|
environment:
|
|
POSTGRES_DB: ${POSTGRES_DB:-wedding}
|
|
POSTGRES_USER: ${POSTGRES_USER:-wedding}
|
|
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
|
|
volumes:
|
|
- postgres_data:/var/lib/postgresql/data
|
|
networks:
|
|
- app_network
|
|
restart: unless-stopped
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER:-wedding}"]
|
|
interval: 5s
|
|
timeout: 5s
|
|
retries: 5
|
|
|
|
backend:
|
|
image: 192.168.31.100:3847/arrelin/wedding-backend:latest
|
|
container_name: wedding_backend
|
|
environment:
|
|
DATABASE_URL: postgres://${POSTGRES_USER:-wedding}:${POSTGRES_PASSWORD}@db:5432/${POSTGRES_DB:-wedding}
|
|
PORT: 8080
|
|
RUST_LOG: ${RUST_LOG:-info}
|
|
depends_on:
|
|
db:
|
|
condition: service_healthy
|
|
networks:
|
|
- app_network
|
|
restart: unless-stopped
|
|
|
|
frontend:
|
|
image: 192.168.31.100:3847/arrelin/wedding-frontend:latest
|
|
container_name: wedding_frontend
|
|
expose:
|
|
- "80"
|
|
depends_on:
|
|
- backend
|
|
networks:
|
|
- app_network
|
|
restart: unless-stopped
|
|
|
|
networks:
|
|
app_network:
|
|
driver: bridge
|
|
|
|
volumes:
|
|
postgres_data:
|
|
driver: local
|