feat: cross-platform compose (Ubuntu CDI + Windows Docker Desktop GPU)

Base compose is GPU-agnostic; GPU is added by a per-OS override selected via
COMPOSE_FILE in .env (docker-compose.gpu-linux.yml for Ubuntu/CDI,
docker-compose.gpu-windows.yml for Windows 11 Docker Desktop). Adds .env.example
split-deployment section + docs/DEPLOY.md covering all-in-one and browser+bot
layouts on both OSes.
This commit is contained in:
javis-bot
2026-06-15 13:00:04 +09:00
parent 8dd6386af8
commit 3bdc7d078a
5 changed files with 153 additions and 8 deletions

View File

@@ -27,10 +27,9 @@ services:
# model resident forever, wasting VRAM next to the chat model.
volumes:
- ollama_models:/root/.ollama
# GPU: needs nvidia-container-toolkit on the host (CDI). Verified on the
# RTX 5050 (Blackwell sm_120) — Ollama offloads 100% to GPU.
devices:
- "nvidia.com/gpu=all"
# GPU is added by a platform override (see docker-compose.gpu-linux.yml /
# docker-compose.gpu-windows.yml + COMPOSE_FILE in .env). Base stays
# GPU-agnostic so the same files run on Ubuntu (CDI) and Windows (Desktop).
# Auto-pull the models the brain needs, then exit. Idempotent (re-runnable).
ollama-init:
@@ -102,10 +101,8 @@ services:
# must NOT pull in Ollama. Full/bot layouts start it with a plain
# `docker compose up -d` (all services); the bridge tolerates Ollama warming
# up lazily, so start order doesn't matter.
# GPU: accelerates Whisper STT (and anything else CUDA) in this container.
# Verified: faster-whisper float16 works on the RTX 5050 (sm_120).
devices:
- "nvidia.com/gpu=all"
# GPU is added by a platform override (docker-compose.gpu-linux.yml /
# docker-compose.gpu-windows.yml). The browser-only host needs no GPU.
shm_size: "1gb" # Chrome needs a larger /dev/shm
ports:
# All published to loopback only by default — VNC/noVNC use a weak default