forked from gtxy27/Harbor-API
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
77 lines (71 loc) · 2.11 KB
/
Copy pathdocker-compose.yml
File metadata and controls
77 lines (71 loc) · 2.11 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
version: '3.4'
services:
new-api:
image: gtxy27/harbor-api:latest
container_name: harbor-api
restart: always
command: --log-dir /app/logs
ports:
- "3000:3000"
volumes:
- ./data:/data
- ./logs:/app/logs
environment:
- SQL_DSN=root:123456@tcp(mysql:3306)/new-api # Point to the mysql service
# - REDIS_CONN_STRING=redis://redis
- TZ=Asia/Shanghai
# - SESSION_SECRET=random_string # 多机部署时设置,必须修改这个随机字符串!!!!!!!
# - NODE_TYPE=slave # Uncomment for slave node in multi-node deployment
# - SYNC_FREQUENCY=60 # Uncomment if regular database syncing is needed
# - FRONTEND_BASE_URL=https://openai.justsong.cn # Uncomment for multi-node deployment with front-end URL
openwebui:
image: ghcr.nju.edu.cn/open-webui/open-webui:main
container_name: openwebui
volumes:
- /var/ai/openwebui/data:/app/backend/data
ports:
- "3001:8080"
environment:
- HF_ENDPOINT=https://hf-mirror.com/
restart: always
logging:
driver: "json-file"
options:
max-size: "200k"
max-file: "10"
# nextchat:
# image: tianzhentech/chatgpt-next-web:latest
# container_name: nextchat
# ports:
# - "3002:3000"
# restart: unless-stopped
# logging:
# driver: "json-file"
# options:
# max-size: "200k"
# max-file: "10"
depends_on:
# - redis
- mysql
healthcheck:
test: [ "CMD-SHELL", "wget -q -O - http://localhost:3000/api/status | grep -o '\"success\":\\s*true' | awk -F: '{print $2}'" ]
interval: 30s
timeout: 10s
retries: 3
# redis:
# image: redis:latest
# container_name: redis
# restart: always
mysql:
image: mysql:8.2
container_name: mysql
restart: always
environment:
MYSQL_ROOT_PASSWORD: 123456 # Ensure this matches the password in SQL_DSN
MYSQL_DATABASE: harbor-api
volumes:
- mysql_data:/var/lib/mysql
# ports:
# - "3306:3306" # If you want to access MySQL from outside Docker, uncomment
volumes:
mysql_data: