File size: 515 Bytes
8e68c3a
6de2f28
 
8e68c3a
6de2f28
 
8e68c3a
6de2f28
 
 
8e68c3a
 
6de2f28
 
 
 
8e68c3a
 
6de2f28
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
version: "3.8"

services:
  ml:
    build: .
    ports:
      - "7860:7860"
    environment:
      - ML_API_KEY=${ML_API_KEY:-smartcertify-dev-key}
      - LOG_LEVEL=${LOG_LEVEL:-INFO}
      - TRANSFORMERS_OFFLINE=1
      - HF_DATASETS_OFFLINE=1
    volumes:
      - ./logs:/app/logs
    restart: unless-stopped
    healthcheck:
      test: ["CMD", "python", "-c",
             "import urllib.request; urllib.request.urlopen('http://localhost:7860/health')"]
      interval: 30s
      timeout: 10s
      retries: 3