x-default: &default restart: unless-stopped logging: driver: json-file options: max-size: 100m max-file: "3" services: gpustack: <<: *default image: gpustack/gpustack:${GPUSTACK_VERSION:-v0.5.3} ports: - "${GPUSTACK_PORT_OVERRIDE:-80}:80" volumes: - gpustack_data:/var/lib/gpustack environment: - TZ=${TZ:-UTC} - GPUSTACK_DEBUG=${GPUSTACK_DEBUG:-false} - GPUSTACK_HOST=${GPUSTACK_HOST:-0.0.0.0} - GPUSTACK_PORT=${GPUSTACK_PORT:-80} - GPUSTACK_TOKEN=${GPUSTACK_TOKEN:-} - GPUSTACK_BOOTSTRAP_PASSWORD=${GPUSTACK_BOOTSTRAP_PASSWORD:-admin} - HF_TOKEN=${HF_TOKEN:-} deploy: resources: limits: cpus: '2.0' memory: 4G reservations: cpus: '1.0' memory: 2G # Uncomment below for GPU support # devices: # - driver: nvidia # count: 1 # capabilities: [gpu] # For GPU support, uncomment the following section # runtime: nvidia healthcheck: test: ["CMD", "wget", "--no-verbose", "--tries=1", "--spider", "http://localhost:80/health"] interval: 30s timeout: 10s retries: 3 start_period: 30s volumes: gpustack_data: