feat: docker compose openwebui

This commit is contained in:
2025-02-05 21:57:12 +08:00
parent be7bf40bb9
commit fcad744044
4 changed files with 65 additions and 14 deletions
+57
View File
@@ -0,0 +1,57 @@
---
volumes:
open_webui: {}
chromadb: {}
ollama: {}
services:
open_webui:
image: ghcr.io/open-webui/open-webui:main
depends_on:
- chromadb
- ollama
environment:
- CHROMA_HTTP_PORT=8000
- CHROMA_HTTP_HOST=chromadb
- CHROMA_TENANT=default_tenant
- VECTOR_DB=chroma
- DATA_DIR=/app/backend/data
- PORT=8080
- WEBUI_URL=http://localhost:8080
- ENABLE_OLLAMA_API=true
# - CORS_ALLOW_ORIGIN="*"
- OLLAMA_BASE_URLS=http://ollama:11434
- RAG_EMBEDDING_ENGINE=ollama
- RAG_EMBEDDING_MODEL=nomic-embed-text-v1.5
- RAG_EMBEDDING_MODEL_TRUST_REMOTE_CODE="True"
volumes:
- open_webui:/app/backend/data
ports:
- "8080:8080"
chromadb:
hostname: chromadb
image: chromadb/chroma:latest
volumes:
- chromadb:/chroma/chroma
environment:
- IS_PERSISTENT=true
- ALLOW_RESET=true
- PERSIST_DIRECTORY=/chroma/chroma
ports:
- "8000:8000"
ollama:
image: ollama/ollama:latest
hostname: ollama
volumes:
- ollama:/root/.ollama
ports:
- "11434:11434"
deploy:
resources:
reservations:
devices:
- driver: nvidia
count: all
capabilities: [gpu]
@@ -0,0 +1,11 @@
services:
test:
image: nvidia/cuda:12.3.1-base-ubuntu20.04
command: nvidia-smi
deploy:
resources:
reservations:
devices:
- driver: nvidia
count: 1
capabilities: [gpu]
+10
View File
@@ -0,0 +1,10 @@
---
services:
openwebui:
image: ghcr.io/open-webui/open-webui:main
ports:
- "3000:8080"
volumes:
- open-webui:/app/backend/data
volumes:
open-webui:
+23
View File
@@ -0,0 +1,23 @@
---
volumes:
db_data:
services:
wordpress:
image: docker.io/library/wordpress:latest
ports:
- 8080:80
environment:
- WORDPRESS_DB_HOST=db
- WORDPRESS_DB_USER=wordpress
- WORDPRESS_DB_PASSWORD=password
- WORDPRESS_DB_NAME=wordpress
db:
image: docker.io/library/mariadb:10.6.4-focal
command: '--default-authentication-plugin=mysql_native_password'
volumes:
- db_data:/var/lib/mysql
environment:
- MYSQL_ROOT_PASSWORD=somewordpress
- MYSQL_DATABASE=wordpress
- MYSQL_USER=wordpress
- MYSQL_PASSWORD=password