services: gpu-hot: build: . container_name: gpu-hot ports: - "1312:1312" environment: - NVIDIA_VISIBLE_DEVICES=all - NVIDIA_DRIVER_CAPABILITIES=all - NODE_NAME=${HOSTNAME} # Optional — override polling intervals (seconds) # - UPDATE_INTERVAL=0.5 # - NVIDIA_SMI_INTERVAL=2.0 deploy: resources: reservations: devices: - driver: nvidia count: all capabilities: [gpu] # To pin specific GPUs instead of "count: all", replace `count` with # `device_ids` and list the UUIDs shown under each card in the UI: # device_ids: # - "GPU-e1924eea-b9bb-d537-39f2-b345087fa145" # - "GPU-899c71bf-27be-b6a0-ae8f-d8afe5ba0f85" init: true pid: "host" restart: unless-stopped healthcheck: test: ["CMD", "curl", "-f", "http://localhost:1312/api/gpu-data"] interval: 30s timeout: 10s retries: 3 start_period: 40s