28 lines
931 B
YAML
28 lines
931 B
YAML
# Ollama, ROCm backend. Serves models on demand — safe to start before
|
|
# you've put anything in /models.
|
|
#
|
|
# Storage: Ollama's content-addressed blob store is bind-mounted under
|
|
# /models/ollama so all model data on the host lives under /models.
|
|
# Note: Ollama's blobs are SHA256-named, not raw GGUFs — llama.cpp/vLLM
|
|
# can't load them directly. Keep curated GGUFs at /models/<vendor>/...
|
|
# for those engines.
|
|
services:
|
|
ollama:
|
|
image: ollama/ollama:rocm
|
|
container_name: ollama
|
|
restart: unless-stopped
|
|
devices:
|
|
- /dev/kfd:/dev/kfd
|
|
- /dev/dri:/dev/dri
|
|
# Numeric GIDs of host's video (44) and render (991) groups — names
|
|
# don't exist inside the container, but the GIDs need to match the
|
|
# host so /dev/kfd + /dev/dri are accessible.
|
|
group_add:
|
|
- "44"
|
|
- "991"
|
|
volumes:
|
|
- /models/ollama:/root/.ollama
|
|
- /models:/models:ro
|
|
ports:
|
|
- "11434:11434"
|