# NVIDIA GPU passthrough overlay (prod) for claw-llamacpp-service.
# Auto-loaded by ../scripts/claw.sh --prod when nvidia-smi is detected.

name: claw

services:
  llamacpp-service:
    deploy:
      resources:
        reservations:
          devices:
            - driver: nvidia
              count: all
              capabilities:
                - gpu
                - compute
                - utility
    environment:
      NVIDIA_VISIBLE_DEVICES: all
      # `graphics` is required so nvidia-container-toolkit mounts NVIDIA's
      # Vulkan ICD into the container. llama.cpp's Linux Vulkan binary is
      # how we get GPU acceleration on NVIDIA without a Linux CUDA prebuilt
      # (upstream stopped publishing those — see binary-releases.constants).
      NVIDIA_DRIVER_CAPABILITIES: compute,utility,graphics
