-
Notifications
You must be signed in to change notification settings - Fork 37
/
compose.yml
67 lines (63 loc) · 1.69 KB
/
compose.yml
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
services:
# Compute Node
compute:
image: "firstbatch/dkn-compute-node:latest"
# build: "./" # use this one instead if you want to build locally
environment:
RUST_LOG: ${RUST_LOG:-none,dkn_compute=info}
# Dria
DKN_WALLET_SECRET_KEY: ${DKN_WALLET_SECRET_KEY}
DKN_ADMIN_PUBLIC_KEY: ${DKN_ADMIN_PUBLIC_KEY}
DKN_MODELS: ${DKN_MODELS}
DKN_P2P_LISTEN_ADDR: ${DKN_P2P_LISTEN_ADDR}
DKN_RELAY_NODES: ${DKN_RELAY_NODES}
DKN_BOOTSTRAP_NODES: ${DKN_BOOTSTRAP_NODES}
# Api Keys
OPENAI_API_KEY: ${OPENAI_API_KEY}
SERPER_API_KEY: ${SERPER_API_KEY}
JINA_API_KEY: ${JINA_API_KEY}
# Ollama
OLLAMA_HOST: ${OLLAMA_HOST}
OLLAMA_PORT: ${OLLAMA_PORT}
OLLAMA_AUTO_PULL: ${OLLAMA_AUTO_PULL:-true}
network_mode: ${DKN_DOCKER_NETWORK_MODE:-bridge}
extra_hosts:
# for Linux, we need to add this line manually
- "host.docker.internal:host-gateway"
restart: "on-failure"
# Ollama Container (CPU)
ollama:
image: ollama/ollama:latest
ports:
- 11434:11434
volumes:
- ~/.ollama:/root/.ollama
profiles: [ollama-cpu]
# Ollama Container (ROCM)
ollama-rocm:
image: ollama/ollama:rocm
ports:
- 11434:11434
volumes:
- ~/.ollama:/root/.ollama
devices:
- "/dev/kfd"
- "/dev/dri"
profiles: [ollama-rocm]
# Ollama Container (CUDA)
ollama-cuda:
image: ollama/ollama
ports:
- 11434:11434
volumes:
- ~/.ollama:/root/.ollama
deploy:
resources:
reservations:
devices:
- driver: nvidia
count: 1
capabilities: [gpu]
profiles: [ollama-cuda]
volumes:
ollama: