Add initial docker-compose configuration for server and client services

This commit is contained in:
MayaTheShy
2026-03-21 16:42:03 -04:00
parent 5bad9a1e71
commit e01a605bb0

31
web/docker-compose.yml Normal file
View File

@@ -0,0 +1,31 @@
version: '3.8'
services:
server:
build: ./server
ports:
- "4200:3001"
networks:
- inventory-network
restart: unless-stopped
healthcheck:
test: ["CMD", "node", "-e", "require('http').get('http://localhost:3001/api/health', (r) => {process.exit(r.statusCode === 200 ? 0 : 1)})"]
interval: 30s
timeout: 3s
start_period: 5s
retries: 3
client:
build: ./client
ports:
- "4444:3000"
networks:
- inventory-network
depends_on:
server:
condition: service_healthy
restart: unless-stopped
networks:
inventory-network:
driver: bridge