services: api: build: . environment: DATABASE_URL: postgresql://postgres:postgres@postgres:5432/interproductec ports: - "8000:8000" depends_on: postgres: condition: service_healthy postgres: image: postgres:18-alpine environment: POSTGRES_USER: postgres POSTGRES_PASSWORD: postgres POSTGRES_DB: interproductec ports: - "5432:5432" volumes: - postgres_data:/var/lib/postgresql healthcheck: test: ["CMD-SHELL", "pg_isready -U postgres -d interproductec"] interval: 5s timeout: 5s retries: 5 volumes: postgres_data: