-
Notifications
You must be signed in to change notification settings - Fork 171
/
Copy pathdocker-compose-warp.yml
80 lines (67 loc) · 1.58 KB
/
docker-compose-warp.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
x-defaults: &defaults
restart: always
env_file:
- .env
labels:
- "com.centurylinklabs.watchtower.enable=true"
services:
web:
image: dairoot/chatgpt-mirror:latest
environment:
- CHATGPT_GATEWAY_URL=http://gateway:8787
ports:
- "50002:50002"
volumes:
- chatgpt_mirror_db:/app/backend/db/
- ./backend/logs:/app/backend/logs
<<: *defaults
gateway:
image: dairoot/chatgpt-gateway:latest
deploy:
replicas: 1 # 账号数量多时可+1
depends_on:
- redis
environment:
- REDIS_URL=redis://redis:6379/0
- PROXY_URL_POOL=socks5://warp:1080 # warp 代理地址
<<: *defaults
cf5s:
image: dairoot/cf5s:latest
depends_on:
- gateway
environment:
- CHATGPT_GATEWAY_URL=http://gateway:8787
<<: *defaults
redis:
image: redis:latest
restart: always
volumes:
- chatgpt_gateway_db:/data
command: ["redis-server", "--appendonly", "yes"]
warp:
image: caomingjun/warp
restart: always
devices:
- /dev/net/tun:/dev/net/tun
ports:
- "1080:1080"
environment:
- WARP_SLEEP=2
cap_add:
- MKNOD
- AUDIT_WRITE
- NET_ADMIN
sysctls:
- net.ipv6.conf.all.disable_ipv6=0
- net.ipv4.conf.all.src_valid_mark=1
volumes:
- ./data:/var/lib/cloudflare-warp
watchtower:
image: containrrr/watchtower
restart: unless-stopped
volumes:
- /var/run/docker.sock:/var/run/docker.sock
command: --cleanup --interval 3600 --label-enable
volumes:
chatgpt_mirror_db:
chatgpt_gateway_db: