-
Notifications
You must be signed in to change notification settings - Fork 111
/
docker-compose-cn.yml
82 lines (77 loc) · 2.02 KB
/
docker-compose-cn.yml
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
name: tidb-ai
services:
redis:
image: registry.cn-beijing.aliyuncs.com/pingcap-ee/redis:6.0.16
restart: always
volumes:
- ./redis-data:/data
command: ["redis-server", "--loglevel", "warning"]
backend:
image: registry.cn-beijing.aliyuncs.com/pingcap-ee/tidb.ai-backend:0.3.0
restart: always
depends_on:
- redis
ports:
- "8000:80"
env_file:
- .env
volumes:
- ./data:/shared/data
logging:
driver: json-file
options:
max-size: "50m"
max-file: "6"
frontend:
image: registry.cn-beijing.aliyuncs.com/pingcap-ee/tidb.ai-frontend:0.3.0
restart: always
depends_on:
- backend
ports:
- 3000:3000
environment:
BASE_URL: http://backend
logging:
driver: json-file
options:
max-size: "50m"
max-file: "6"
background:
image: registry.cn-beijing.aliyuncs.com/pingcap-ee/tidb.ai-backend:0.3.0
restart: always
depends_on:
- redis
ports:
- "5555:5555"
env_file:
- .env
volumes:
- ./data:/shared/data
command: /usr/bin/supervisord
logging:
driver: json-file
options:
max-size: "50m"
max-file: "6"
local-embedding-reranker:
image: registry.cn-beijing.aliyuncs.com/pingcap-ee/tidb.ai-local-embedding-reranker:v4-with-cache
ports:
- 5001:5001
environment:
- HF_ENDPOINT=https://hf-mirror.com
- PRE_LOAD_DEFAULT_EMBEDDING_MODEL=true
# If you want to pre-load the default reranker model, change the following environment to true
- PRE_LOAD_DEFAULT_RERANKER_MODEL=false
- TRANSFORMERS_OFFLINE=1
# volumes:
# - ./local-embedding-reranker:/root/.cache/huggingface
# If you are using NVIDIA GPU, you can uncomment the following lines to enable GPU support
# deploy:
# resources:
# reservations:
# devices:
# - driver: nvidia
# count: 1
# capabilities: [gpu]
profiles:
- local-embedding-reranker