forked from primihub/primihub
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose-dev.yml
107 lines (101 loc) · 2.4 KB
/
docker-compose-dev.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
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
version: '3'
services:
node0:
build:
context: .
dockerfile: Dockerfile
restart: "no"
hostname: node0_primihub
container_name: node0_primihub
ports:
- "8050:50050"
- "10120:12120"
- "10121:12121"
volumes:
- ./config:/app/config
extra_hosts:
- "node0_primihub:172.28.1.10"
- "node1_primihub:172.28.1.11"
- "node2_primihub:172.28.1.12"
working_dir: /app
entrypoint:
- "/bin/bash"
- "-c"
- "./primihub-node --service_port=50050 --node_id=node0 --config=/app/config/primihub_node0.yaml"
networks:
dev_net:
ipv4_address: 172.28.1.10
depends_on:
- simple_bootstrap_node
# node1
node1:
build:
context: .
dockerfile: Dockerfile
restart: "no"
hostname: node1_primihub
container_name: node1_primihub
ports:
- "8051:50050"
- "11120:12120"
- "11121:12121"
volumes:
- ./config:/app/config
extra_hosts:
- "node0_primihub:172.28.1.10"
- "node1_primihub:172.28.1.11"
- "node2_primihub:172.28.1.12"
working_dir: /app
entrypoint:
- "/bin/bash"
- "-c"
- "./primihub-node --service_port=50050 --node_id=node1 --config=/app/config/primihub_node1.yaml"
networks:
dev_net:
ipv4_address: 172.28.1.11
depends_on:
- simple_bootstrap_node
node2:
build:
context: .
dockerfile: Dockerfile
restart: "no"
hostname: node2_primihub
container_name: node2_primihub
ports:
- "8052:50050"
- "12120:12120"
- "12121:12121"
volumes:
- ./config:/app/config
extra_hosts:
- "node0_primihub:172.28.1.10"
- "node1_primihub:172.28.1.11"
- "node2_primihub:172.28.1.12"
working_dir: /app
entrypoint:
- "/bin/bash"
- "-c"
- "./primihub-node --service_port=50050 --node_id=node2 --config=/app/config/primihub_node2.yaml"
networks:
dev_net:
ipv4_address: 172.28.1.12
depends_on:
- simple_bootstrap_node
simple_bootstrap_node:
image: primihub/simple-bootstrap-node:1.0
container_name: simple_bootstrap_node
restart: "always"
ports:
- "4001:4001"
entrypoint:
- "/app/simple-bootstrap-node"
networks:
dev_net:
ipv4_address: 172.28.1.13
networks:
dev_net:
driver: bridge
ipam:
config:
- subnet: 172.28.0.0/16