Files
docker-swarm-termina/docker-compose.yml
Claude cd16fbc6bb Add tests with coverage and e2e to Docker build process
- Update backend Dockerfile with multi-stage build that runs pytest
  with coverage (70% threshold) before production build
- Update frontend Dockerfile with multi-stage build including:
  - Unit test stage with Jest coverage
  - E2E test stage with Playwright
  - Production stage depends on test stages via markers
- Add Playwright e2e tests for login, dashboard, and terminal flows
- Configure Playwright with chromium browser
- Update jest.config.js to exclude e2e directory
- Update docker-compose.yml to target production stage

https://claude.ai/code/session_01XSQJybTpvKyN7td4Y8n5Rm
2026-02-01 17:10:32 +00:00

32 lines
651 B
YAML

version: '3.8'
services:
backend:
build:
context: ./backend
dockerfile: Dockerfile
target: production
ports:
- "5000:5000"
environment:
- ADMIN_USERNAME=admin
- ADMIN_PASSWORD=admin123
volumes:
- /var/run/docker.sock:/var/run/docker.sock
restart: unless-stopped
frontend:
build:
context: ./frontend
dockerfile: Dockerfile
target: production
args:
- NEXT_PUBLIC_API_URL=http://localhost:5000
ports:
- "3000:3000"
environment:
- NEXT_PUBLIC_API_URL=http://backend:5000
depends_on:
- backend
restart: unless-stopped