-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
57 lines (50 loc) · 1.18 KB
/
docker-compose.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
version: '3'
services:
web:
image: nginx:latest
ports:
- "80:80"
volumes:
- "./client/nginx.conf:/etc/nginx/conf.d/default.conf"
- "./client/tmp:/usr/share/nginx/html"
command: /bin/bash -c "nginx -g 'daemon off;'"
networks:
nn:
ipv4_address: 192.168.5.101
django:
build:
context: ./server
dockerfile: Dockerfile
ports:
- "8080:8080"
volumes:
- ./server:/home/app
- ./server/db:/home/app/db/
environment:
- CENTRIFUGE_ADDRESS=http://192.168.5.103:8000
- CENTRIFUGE_SECRET=c597cc75-0c39-49b9-84b9-dffb5ec54873
networks:
nn:
ipv4_address: 192.168.5.102
centrifugo:
image: centrifugo/centrifugo
ulimits:
nproc: 65536
nofile:
soft: 65536
hard: 65536
ports:
- "8000:8000"
volumes:
- ./centrifugo:/centrifugo
command: centrifugo -c /centrifugo/config.json --admin
networks:
nn:
ipv4_address: 192.168.5.103
networks: ##定义网络组
nn: ## 网络组名称
driver: bridge ## 网络的模式
ipam: ## 配置网络
driver: default
config:
- subnet: 192.168.5.0/24