sdlc-project/backend/docker-compose-x86_64.yaml
hasslesstech 642c1fa944
All checks were successful
test-backend / test-x86_64 (push) Successful in 22s
add postgresql container to run tests in
2025-05-25 19:51:17 +03:00

38 lines
764 B
YAML

services:
postgres:
image: postgres
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
- POSTGRES_DB=postgres
networks:
- testing
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER} -d ${POSTGRES_DB}"]
interval: 10s
retries: 5
start_period: 30s
timeout: 3s
backend:
image: 10.5.1.5:5000/sdlc/x86_64
ports:
- "80:9090"
volumes:
- "./src/:/app:ro"
environment:
- DB_NAME=postgres
- DB_USER=postgres
- DB_PASS=postgres
- DB_HOST=postgres
- DB_PORT=5432
networks:
- testing
depends_on:
postgres:
condition: service_healthy
# restart: true
networks:
testing: