version: '3.9' services: # Backend Service - Bun + Hono OAuth Server backend: build: context: . dockerfile: Dockerfile.backend container_name: job-info-backend ports: - "3005:3005" environment: - NODE_ENV=production - PORT=3005 - LOG_LEVEL=info - OAUTH_CLIENT_ID=${OAUTH_CLIENT_ID} - OAUTH_CLIENT_SECRET=${OAUTH_CLIENT_SECRET} - OAUTH_REDIRECT_URI=http://localhost:5173/#/callback - CORS_ORIGIN=http://localhost:5173 volumes: - ./Mode3Test/backend:/app/backend:ro networks: - job-info-network healthcheck: test: ["CMD", "curl", "-f", "http://localhost:3005/health"] interval: 30s timeout: 10s retries: 3 start_period: 10s restart: unless-stopped # Frontend Service - Node + Vite + Svelte frontend: build: context: . dockerfile: Dockerfile.frontend container_name: job-info-frontend ports: - "5173:5173" environment: - NODE_ENV=production depends_on: backend: condition: service_healthy networks: - job-info-network healthcheck: test: ["CMD", "wget", "--quiet", "--tries=1", "--spider", "http://localhost:5173"] interval: 30s timeout: 10s retries: 3 start_period: 10s restart: unless-stopped networks: job-info-network: driver: bridge # Usage: # Development: docker-compose up # Production: docker-compose -f docker-compose.yml up -d # Build only: docker-compose build # Cleanup: docker-compose down -v