| version: "3.9" | |
| services: | |
| rox-ai: | |
| build: | |
| context: . | |
| dockerfile: Dockerfile | |
| container_name: rox-ai | |
| ports: | |
| - "8000:8000" | |
| env_file: | |
| - .env | |
| environment: | |
| - PORT=8000 | |
| - ALLOWED_ORIGINS=http://localhost:3000,https://Rox-Turbo-API.hf.space | |
| restart: unless-stopped | |
| healthcheck: | |
| test: ["CMD", "python", "-c", "import requests; requests.get('http://localhost:8000/health', timeout=5)"] | |
| interval: 30s | |
| timeout: 10s | |
| retries: 3 | |
| start_period: 10s | |
| deploy: | |
| resources: | |
| limits: | |
| cpus: '2' | |
| memory: 2G | |
| reservations: | |
| cpus: '0.5' | |
| memory: 512M | |
| security_opt: | |
| - no-new-privileges:true | |
| read_only: false | |
| tmpfs: | |
| - /tmp | |
| logging: | |
| driver: "json-file" | |
| options: | |
| max-size: "10m" | |
| max-file: "3" | |