ci: stabilize pipeline
All checks were successful
CI / Backend Tests (push) Successful in 31s
CI / Frontend Tests (push) Successful in 1m43s
CI / Build Docker Images (push) Successful in 4m45s

This commit is contained in:
2025-10-16 21:00:39 -05:00
parent 96dc42f0eb
commit a553b14017
12 changed files with 204 additions and 102 deletions

View File

@@ -3,13 +3,18 @@ services:
image: postgres:15-alpine
container_name: merchantsofhope-supplyanddemandportal-database
environment:
POSTGRES_DB: merchantsofhope_supplyanddemandportal
POSTGRES_USER: merchantsofhope_user
POSTGRES_PASSWORD: merchantsofhope_password
POSTGRES_DB: ${POSTGRES_DB:-merchantsofhope_supplyanddemandportal}
POSTGRES_USER: ${POSTGRES_USER:-merchantsofhope_user}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:?POSTGRES_PASSWORD is not set}
expose:
- "5432"
volumes:
- merchantsofhope-supplyanddemandportal-postgres-data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER:-merchantsofhope_user}"]
interval: 10s
timeout: 5s
retries: 5
networks:
- merchantsofhope-supplyanddemandportal-network
@@ -20,14 +25,17 @@ services:
container_name: merchantsofhope-supplyanddemandportal-backend
environment:
NODE_ENV: development
DATABASE_URL: postgresql://merchantsofhope_user:merchantsofhope_password@merchantsofhope-supplyanddemandportal-database:5432/merchantsofhope_supplyanddemandportal
JWT_SECRET: merchantsofhope_jwt_secret_key_2024
DATABASE_URL: postgresql://${POSTGRES_USER:-merchantsofhope_user}:${POSTGRES_PASSWORD}@merchantsofhope-supplyanddemandportal-database:5432/${POSTGRES_DB:-merchantsofhope_supplyanddemandportal}
JWT_SECRET: ${JWT_SECRET:?JWT_SECRET is not set}
HOST: ${BACKEND_HOST:-0.0.0.0}
PORT: ${BACKEND_PORT:-3001}
expose:
- "3001"
ports:
- "0.0.0.0:${BACKEND_PORT:-3001}:3001"
command: >
sh -c "npm run migrate && npm run seed && npm run dev"
depends_on:
- merchantsofhope-supplyanddemandportal-database
merchantsofhope-supplyanddemandportal-database:
condition: service_healthy
volumes:
- ./backend:/app
- /app/node_modules