Skip to content

Commit cee9a53

Browse files
authored
Merge pull request #1277 from Websoft9/update-openwebui-a454f66f
Update openwebui
2 parents 52271cc + 381c28e commit cee9a53

File tree

5 files changed

+96
-77
lines changed

5 files changed

+96
-77
lines changed

apps/openwebui/.env

Lines changed: 12 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -1,47 +1,19 @@
1-
W9_REPO=wordpress
2-
W9_DIST=community
3-
W9_VERSION=latest
4-
5-
W9_POWER_PASSWORD=1PrMxExC45LsCT
6-
7-
# Environments which for user settings when create application
8-
# Named expression: W9_xxx_xxx_SET, xxx refer to file fields
9-
W9_HTTP_PORT_SET=9001
10-
# W9_HTTPS_PORT_SET=9002
11-
# W9_DB_PORT_SET=3306
12-
# W9_SSH_PORT_SET=23
13-
W9_KEY_SET="dfsjdkjf77xjxcjcj"
14-
15-
#### -- Not allowed to edit below environments when recreate app based on existing data -- ####
16-
17-
W9_ID=openwebui
18-
19-
# W9_HTTP_PORT or W9_HTTPS_PORT is need at leaset and used for proxy for web application
20-
# Some container (e.g teleport) need HTTPS access, then need to set this pra
21-
W9_HTTP_PORT=80
22-
W9_HTTPS_PORT=81
23-
24-
W9_LOGIN_USER=admin
25-
# use https://1password.com/zh-cn/password-generator/ to genarate 14 bit password
26-
# this password can also use password file
27-
W9_LOGIN_PASSWORD=$W9_POWER_PASSWORD
28-
W9_ADMIN_PATH="/wp-login"
29-
30-
# Container name's suffix must use one of the value
31-
W9_DB_EXPOSE="mysql,postgresql,mariadb,mongodb,redis"
32-
33-
# It is used when the application APP needs to set an external URL, which can be IP(or domain), IP:PORT
34-
# If have protocols, should be set it in the APP's ENV
35-
W9_URL=internet_ip:$W9_HTTP_PORT_SET
36-
# modifies W9_URL on init when it is true
37-
W9_URL_REPLACE=true
38-
1+
W9_REPO=ghcr.io/open-webui/open-webui
2+
W9_DIST='community'
3+
W9_VERSION='main'
4+
W9_POWER_PASSWORD='dx8!BEMBUxd6qHlU'
5+
6+
W9_HTTP_PORT=8080
7+
W9_HTTP_PORT_SET='9001'
8+
W9_ID='openwebui'
9+
W9_URL='internet_ip:$W9_HTTP_PORT_SET'
3910
W9_NETWORK=websoft9
4011

4112
#### ----------------------------------------------------------------------------------------- ####
4213

4314

44-
# Below environment is created by apphub
15+
# Below environment is created by this app: https://docs.openwebui.com/getting-started/env-configuration
4516

4617
#W9_NAME=""
47-
#W9_RCODE=""
18+
#W9_RCODE=""
19+
OLLAMA_BASE_URL=http://$W9_ID-ollama:11434

apps/openwebui/Notes.md

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,22 @@
1-
# Appname
1+
# Open WebUI
2+
3+
## Guide
4+
5+
### Quick Start
6+
7+
1. Create administrator credential when Open WebUI setup
8+
2. Go to the **Settings > Admin Settings** to add a LLM, e.g [tinydolphin](https://ollama.com/library/tinydolphin) which not exceeding 1GB
9+
3. You can select **tinydolphin** for chat now
10+
11+
### Running with GPU?
12+
13+
1. Select version **cuda** when create this application
14+
2. Edit this application with Compose and change `docker-compose-gpu.yml` to `docker-compose.yml`
15+
3. Recreate this application
16+
17+
### Config
18+
19+
- Config Ollama URL: **设置 > 管理员设置**
20+
- Mutiply Languages: Yes
21+
222
## FAQ
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# docs: https://docs.openwebui.com/getting-started/quick-start/
2+
3+
services:
4+
5+
app:
6+
image: $W9_REPO:$W9_VERSION
7+
container_name: $W9_ID
8+
restart: unless-stopped
9+
ports:
10+
- $W9_HTTP_PORT_SET:8080
11+
env_file: .env
12+
volumes:
13+
- open-webui:/app/backend/data
14+
deploy:
15+
reservations:
16+
devices:
17+
- driver: nvidia
18+
count: all
19+
capabilities: [gpu]
20+
21+
ollama:
22+
image: ollama/ollama
23+
container_name: $W9_ID-ollama
24+
restart: unless-stopped
25+
deploy:
26+
resources:
27+
limits:
28+
memory: 5g
29+
cpus: '2'
30+
reservations:
31+
devices:
32+
- driver: nvidia
33+
count: all
34+
capabilities: [gpu]
35+
volumes:
36+
- ollama:/root/.ollama
37+
38+
volumes:
39+
open-webui:
40+
ollama:
41+
42+
networks:
43+
default:
44+
name: $W9_NETWORK
45+
external: true

apps/openwebui/docker-compose.yml

Lines changed: 16 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,50 +1,34 @@
1-
# image,docs: https://hub.docker.com/_/wordpress/
1+
# docs: https://docs.openwebui.com/getting-started/quick-start/
22

33
services:
44

5-
wordpress:
5+
app:
66
image: $W9_REPO:$W9_VERSION
77
container_name: $W9_ID
88
restart: unless-stopped
9-
#This is for access host from container
10-
# extra_hosts: ["host.docker.internal:host-gateway"]
11-
# command: |
12-
# /bin/bash -c "ping -c 3 host.docker.internal"
13-
logging:
14-
driver: "json-file"
15-
options:
16-
max-file: "5"
17-
max-size: 10m
18-
deploy:
19-
resources:
20-
limits:
21-
memory: 5g
22-
cpus: '0.7'
239
ports:
24-
- $W9_HTTP_PORT_SET:80
10+
- $W9_HTTP_PORT_SET:8080
2511
env_file: .env
2612
volumes:
27-
- wordpress:/var/www/html
28-
- ./src/php_exra.ini:/usr/local/etc/php/conf.d/php_exra.ini
13+
- open-webui:/app/backend/data
2914

30-
mariadb:
31-
image: mariadb:10.4
32-
container_name: $W9_ID-mariadb
15+
ollama:
16+
image: ollama/ollama
17+
container_name: $W9_ID-ollama
3318
restart: unless-stopped
34-
command: --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci --innodb_log_buffer_size=30M
19+
deploy:
20+
resources:
21+
limits:
22+
memory: 5g
23+
cpus: '2'
3524
volumes:
36-
- mysql_data:/var/lib/mysql
37-
environment:
38-
MYSQL_DATABASE: $W9_ID
39-
MYSQL_USER: $W9_ID
40-
MYSQL_PASSWORD: $W9_POWER_PASSWORD
41-
MYSQL_ROOT_PASSWORD: $W9_POWER_PASSWORD
25+
- ollama:/root/.ollama
4226

4327
volumes:
44-
wordpress:
45-
mysql_data:
28+
open-webui:
29+
ollama:
4630

4731
networks:
4832
default:
4933
name: $W9_NETWORK
50-
external: true
34+
external: true

apps/openwebui/variables.json

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,13 @@
77
"edition": [
88
{
99
"dist": "community",
10-
"version": [
11-
"latest"
12-
]
10+
"version": ["main","cuda"]
1311
}
1412
],
1513
"requirements": {
1614
"cpu": "2",
1715
"memory": "4",
18-
"disk": "1",
16+
"disk": "10",
1917
"url": "https://openwebui.com"
2018
}
2119
}

0 commit comments

Comments
 (0)