-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathdocker-compose.yaml
More file actions
107 lines (99 loc) · 2.75 KB
/
docker-compose.yaml
File metadata and controls
107 lines (99 loc) · 2.75 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
# Magec - Fully local deployment
# Everything runs on your machine: LLM, STT, TTS, embeddings, memory.
# No API keys, no cloud accounts, no data leaving your network.
#
# GPU: Uncomment ONE of the GPU sections under ollama:
# - Docker: the 'deploy' block (uses nvidia container runtime)
# - Podman: the 'devices' line (uses CDI — requires nvidia-ctk cdi generate)
#
# Usage:
# docker compose up -d
# docker compose logs -f ollama-setup # watch model downloads on first start
services:
magec:
image: ghcr.io/achetronic/magec:latest
ports:
- "8080:8080"
- "8081:8081"
volumes:
- ./config.yaml:/app/config.yaml
- magec_data:/app/data
depends_on:
ollama-setup:
condition: service_completed_successfully
redis:
condition: service_started
postgres:
condition: service_started
parakeet:
condition: service_started
tts:
condition: service_started
restart: unless-stopped
redis:
image: docker.io/library/redis:alpine
volumes:
- redis_data:/data
restart: unless-stopped
postgres:
image: docker.io/pgvector/pgvector:pg17
environment:
POSTGRES_USER: magec
POSTGRES_PASSWORD: magec
POSTGRES_DB: magec
volumes:
- postgres_data:/var/lib/postgresql/data
restart: unless-stopped
ollama:
image: docker.io/ollama/ollama:latest
volumes:
- ollama_data:/root/.ollama
restart: unless-stopped
# ── NVIDIA GPU acceleration (uncomment ONE option) ──────────────
#
# Option A — Docker (nvidia-container-runtime):
# deploy:
# resources:
# reservations:
# devices:
# - driver: nvidia
# count: all
# capabilities: [gpu]
#
# Option B — Podman (CDI — run: sudo nvidia-ctk cdi generate --output=/etc/cdi/nvidia.yaml):
# devices:
# - nvidia.com/gpu=all
ollama-setup:
image: docker.io/ollama/ollama:latest
depends_on:
- ollama
restart: "no"
environment:
OLLAMA_HOST: http://ollama:11434
entrypoint: [""]
command:
- /bin/sh
- -c
- |
echo "Waiting for Ollama to be ready..."
until ollama list > /dev/null 2>&1; do
sleep 2
done
echo "Pulling qwen3:8b (LLM)..."
ollama pull qwen3:8b
echo "Pulling nomic-embed-text (embeddings)..."
ollama pull nomic-embed-text
echo "Models ready."
parakeet:
image: ghcr.io/achetronic/parakeet:latest
restart: unless-stopped
tts:
image: docker.io/travisvn/openai-edge-tts:latest
environment:
- REQUIRE_API_KEY=False
restart: unless-stopped
volumes:
magec_data:
redis_data:
postgres_data:
ollama_data: