You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 

34 lines
739 B

version: '3.8'
services:
face-recognition-api:
build: .
container_name: face-recognition-api
ports:
- "8000:8000"
volumes:
- ./data:/app/data # For persisting face data
environment:
- PYTHONUNBUFFERED=1
- MAX_WORKERS=4
- FACE_DETECTION_SIZE=640
- SIMILARITY_THRESHOLD=0.6
deploy:
resources:
limits:
cpus: '2'
memory: 4G
reservations:
cpus: '1'
memory: 2G
restart: unless-stopped
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8000/"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
networks:
default:
driver: bridge