version: '3.8' services: web: build: ./backend container_name: imapsync-web ports: - "8080:8080" volumes: - ./data:/data environment: - DB_PATH=/data/imapsync.db - LOG_DIR=/data/logs - SECRET_KEY=change-me-in-production restart: unless-stopped healthcheck: test: ["CMD", "curl", "-f", "http://localhost:8080/api/health"] interval: 30s timeout: 10s retries: 3 worker: build: ./worker container_name: imapsync-worker volumes: - ./data:/data environment: - DB_PATH=/data/imapsync.db - LOG_DIR=/data/logs - POLL_INTERVAL=15 restart: unless-stopped depends_on: web: condition: service_healthy volumes: data: