-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yaml
More file actions
96 lines (92 loc) · 2.57 KB
/
docker-compose.yaml
File metadata and controls
96 lines (92 loc) · 2.57 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
services:
ollama:
image: ollama/ollama:latest
ports:
- 11434:11434
volumes:
- ./scripts:/scripts
- ./ollama/ollama:/root/.ollama
container_name: ollama
pull_policy: always
tty: true
restart: always
entrypoint: ["/scripts/entrypoint.sh"]
environment:
- OLLAMA_KEEP_ALIVE=24h
- OLLAMA_HOST=0.0.0.0
- OLLAMA_TIMEOUT=10
- OLLAMA_MAX_PARALLEL_REQUESTS=10
# variables also used in agent container
- OLLAMA_MODEL_NAME=${OLLAMA_MODEL_NAME}
healthcheck:
test: ["CMD-SHELL", "curl -f http://localhost:11434/api/tags"]
interval: 10s
timeout: 2s
retries: 3
start_period: 20s
ollama-webui:
image: ghcr.io/open-webui/open-webui:main
container_name: ollama-webui
volumes:
- ./ollama/ollama-webui:/app/backend/data
depends_on:
- ollama
ports:
- 8080:8080
environment: # https://docs.openwebui.com/getting-started/env-configuration#default_models
- OLLAMA_BASE_URLS=http://host.docker.internal:11434 #comma separated ollama hosts
- WEBUI_AUTH=False
- WEBUI_NAME=Trino
- WEBUI_URL=http://localhost:8080
- WEBUI_SECRET_KEY=t0p-s3cr3t
- BYPASS_MODEL_ACCESS_CONTROL=True
- DEFAULT_MODELS=llama3.2,deepseek-r1:1.5b
extra_hosts:
- host.docker.internal:host-gateway
restart: unless-stopped
backend:
build:
context: ./backend
dockerfile: Dockerfile.backend
command: uvicorn app:app --host 0.0.0.0 --port 8000
ports:
- "8000:8000"
volumes:
- ./backend:/app
agent:
build:
context: .
dockerfile: ./my_agent/Dockerfile.agent
depends_on:
ollama:
condition: service_healthy
backend:
condition: service_started
volumes:
- .:/project
restart: always
environment:
- COLLECTION_NAME=my_collection
- BACKEND_CRAWLSVC_URL=http://backend:8000
- TRINO_RELEASE_URL=https://trino.io/docs/current/release.html
- OLLAMA_MODEL_NAME=${OLLAMA_MODEL_NAME}
- OLLAMA_BASE_URL=http://ollama:11434
- OLLAMA_NUM_CTX=8192
- LOG_LEVEL=INFO # Can be DEBUG, INFO, WARNING, ERROR, CRITICAL
- VERSION_START=${VERSION_START}
- VERSION_END=${VERSION_END}
gradio:
build:
context: .
dockerfile: gradio/Dockerfile.gradio
ports:
- "7860:7860"
depends_on:
- backend
- agent
volumes:
- .:/app
environment:
# variables also used in agent container
- BACKEND_CRAWLSVC_URL=http://backend:8000
- OLLAMA_BASE_URL=http://ollama:11434