open-webui/docker-compose.yml

45 lines
969 B
YAML
Raw Normal View History

2023-10-30 19:52:45 +00:00
version: '3.6'
services:
ollama:
2023-10-31 02:28:05 +00:00
# Uncomment below for GPU support
2023-10-30 20:12:33 +00:00
# deploy:
# resources:
# reservations:
# devices:
# - driver: nvidia
# count: 1
# capabilities:
# - gpu
2023-10-30 19:52:45 +00:00
volumes:
- ollama:/root/.ollama
2023-11-17 18:38:29 +00:00
# Uncomment below to expose Ollama API outside the container stack
# ports:
# - 11434:11434
2023-10-30 19:52:45 +00:00
container_name: ollama
pull_policy: always
tty: true
restart: unless-stopped
image: ollama/ollama:latest
ollama-webui:
build:
context: .
args:
OLLAMA_API_BASE_URL: '/ollama/api'
2023-10-30 19:52:45 +00:00
dockerfile: Dockerfile
image: ollama-webui:latest
container_name: ollama-webui
2023-11-17 18:38:29 +00:00
depends_on:
- ollama
2023-10-30 19:52:45 +00:00
ports:
- 3000:8080
2023-11-17 18:38:29 +00:00
environment:
- "OLLAMA_API_BASE_URL=http://ollama:11434/api"
extra_hosts:
2023-11-17 18:38:29 +00:00
- host.docker.internal:host-gateway
restart: unless-stopped
2023-10-30 19:52:45 +00:00
volumes:
ollama: {}