Files
MOHPortal/deploy/coolify/docker-compose.yml
ReachableCEO 42dc3c8097
Some checks failed
CI / Backend Tests (push) Has been cancelled
CI / Frontend Tests (push) Has been cancelled
CI / Build Docker Images (push) Has been cancelled
Prepare CI and deployment scaffolding
2025-10-16 17:18:18 -05:00

46 lines
1.7 KiB
YAML

version: '3.9'
services:
merchantsofhope-supplyanddemandportal-database:
image: postgres:15-alpine
container_name: merchantsofhope-supplyanddemandportal-database
environment:
POSTGRES_DB: ${POSTGRES_DB:-merchantsofhope_supplyanddemandportal}
POSTGRES_USER: ${POSTGRES_USER:-merchantsofhope}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:?set POSTGRES_PASSWORD}
volumes:
- merchantsofhope-supplyanddemandportal-postgres-data:/var/lib/postgresql/data
healthcheck:
test: ["CMD", "pg_isready", "-U", "${POSTGRES_USER:-merchantsofhope}"]
interval: 10s
timeout: 5s
retries: 5
merchantsofhope-supplyanddemandportal-backend:
image: ${BACKEND_IMAGE:?set BACKEND_IMAGE}
container_name: merchantsofhope-supplyanddemandportal-backend
depends_on:
merchantsofhope-supplyanddemandportal-database:
condition: service_healthy
environment:
NODE_ENV: production
PORT: 3001
DATABASE_URL: postgresql://${POSTGRES_USER:-merchantsofhope}:${POSTGRES_PASSWORD}@merchantsofhope-supplyanddemandportal-database:5432/${POSTGRES_DB:-merchantsofhope_supplyanddemandportal}
JWT_SECRET: ${JWT_SECRET:?set JWT_SECRET}
ports:
- "0.0.0.0:3001:3001"
merchantsofhope-supplyanddemandportal-frontend:
image: ${FRONTEND_IMAGE:?set FRONTEND_IMAGE}
container_name: merchantsofhope-supplyanddemandportal-frontend
depends_on:
- merchantsofhope-supplyanddemandportal-backend
environment:
PORT: 3000
REACT_APP_API_URL: ${REACT_APP_API_URL:-http://merchantsofhope-supplyanddemandportal-backend:3001}
ports:
- "0.0.0.0:3000:3000"
volumes:
merchantsofhope-supplyanddemandportal-postgres-data: