1
0
mirror of https://gitlab.com/MoonTestUse1/AdministrationItDepartmens.git synced 2025-08-14 00:25:46 +02:00
Files
AdministrationItDepartmens/docker-compose.yml
2025-01-02 00:55:37 +06:00

54 lines
1.2 KiB
YAML

version: '3.8'
services:
frontend:
build: frontend
container_name: support-frontend
ports:
- "80:80"
depends_on:
- backend
networks:
- support-network
backend:
build: backend
container_name: support-backend
environment:
- DATABASE_URL=postgresql://postgres:postgres123@postgres:5432/support_db
ports:
- "8000:8000"
depends_on:
postgres:
condition: service_healthy
networks:
- support-network
restart: unless-stopped
postgres:
image: postgres:15
container_name: support-postgres
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres123
POSTGRES_DB: support_db
POSTGRES_HOST_AUTH_METHOD: trust
volumes:
- postgres_data:/var/lib/postgresql/data
- ./backend/docker/postgres/init.sql:/docker-entrypoint-initdb.d/init.sql
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres -d support_db"]
interval: 5s
timeout: 5s
retries: 5
start_period: 5s
networks:
- support-network
restart: unless-stopped
networks:
support-network:
driver: bridge
volumes:
postgres_data: