forked from mysteriumnetwork/node
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.localnet.yml
402 lines (384 loc) · 8.94 KB
/
docker-compose.localnet.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
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
version: '3.0'
services:
morqa:
image: mysteriumnetwork/quality-oracle:latest
command: >
--bind-addr=:8085
--prometheus=http://prometheus:9090
--metrics-addr=:8080
depends_on:
- prometheus
expose:
- 8085
- 8080
cap_add:
- NET_ADMIN
sysctls:
- net.ipv4.conf.default.rp_filter=0
- net.ipv4.conf.all.rp_filter=0
- net.ipv4.conf.eth0.rp_filter=0
- net.ipv4.conf.eth1.rp_filter=0
dns: 172.30.0.254
networks:
public0:
ipv4_address: 172.30.0.198
public1:
ipv4_address: 172.31.0.198
prometheus:
image: prom/prometheus:v2.10.0
volumes:
- ./e2e/prometheus:/prometheus
command:
- '--config.file=/prometheus/prometheus-local.yml'
- '--storage.tsdb.path=/data'
expose:
- 9090
dns: 172.30.0.254
networks:
public0:
ipv4_address: 172.30.0.199
public1:
ipv4_address: 172.31.0.199
ipify:
image: owlab/ipify
expose:
- 3000
cap_add:
- NET_ADMIN
sysctls:
- net.ipv4.conf.default.rp_filter=0
- net.ipv4.conf.all.rp_filter=0
- net.ipv4.conf.eth0.rp_filter=0
- net.ipv4.conf.eth1.rp_filter=0
dns: 172.30.0.254
networks:
public0:
ipv4_address: 172.30.0.10
public1:
ipv4_address: 172.31.0.10
broker-real:
image: nats:1.0.4
expose:
- 4222
cap_add:
- NET_ADMIN
sysctls:
- net.ipv4.conf.default.rp_filter=0
- net.ipv4.conf.all.rp_filter=0
- net.ipv4.conf.eth0.rp_filter=0
- net.ipv4.conf.eth1.rp_filter=0
dns: 172.30.0.254
networks:
public0:
ipv4_address: 172.30.0.30
public1:
ipv4_address: 172.31.0.30
broker:
image: mysteriumnetwork/nats-proxy:1.0.1
depends_on:
- broker-real
expose:
- 4222
cap_add:
- NET_ADMIN
sysctls:
- net.ipv4.conf.default.rp_filter=0
- net.ipv4.conf.all.rp_filter=0
- net.ipv4.conf.eth0.rp_filter=0
- net.ipv4.conf.eth1.rp_filter=0
dns: 172.30.0.254
networks:
public0:
ipv4_address: 172.30.0.31
public1:
ipv4_address: 172.31.0.31
db:
image: percona:5.7
cap_add:
- NET_ADMIN
restart: always
expose:
- 3306
environment:
MYSQL_ROOT_PASSWORD: root
MYSQL_DATABASE: myst_api
MYSQL_USER: myst_api
MYSQL_PASSWORD: myst_api
dns: 172.30.0.254
networks:
public0:
ipv4_address: 172.30.0.201
public1:
ipv4_address: 172.31.0.201
mysterium-api:
image: mysteriumnetwork/mysterium-api:0.5.22
expose:
- 8001
cap_add:
- NET_ADMIN
sysctls:
- net.ipv4.conf.default.rp_filter=0
- net.ipv4.conf.all.rp_filter=0
- net.ipv4.conf.eth0.rp_filter=0
- net.ipv4.conf.eth1.rp_filter=0
environment:
APP_PORT: 8001
DB_HOST: db
DB_NAME: myst_api
DB_USER: myst_api
DB_PASSWORD: myst_api
ETHER_RPC_URL: "http://ganache:8545"
IDENTITY_CONTRACT: "0x1955141ba8e77a5B56efBa8522034352c94f77Ea"
ETHER_MINING_MODE: "poa"
DISCOVERY_VERIFY_IDENTITY: "false"
depends_on:
- db
- ganache
dns: 172.30.0.254
networks:
public0:
ipv4_address: 172.30.0.200
public1:
ipv4_address: 172.31.0.200
# private blockchain
ganache:
image: trufflesuite/ganache-cli:v6.6.0-beta.0
expose:
- 8545
command: >
--mnemonic "amused glory pen avocado toilet dragon entry kitchen cliff retreat canyon danger"
dns: 172.30.0.254
sysctls:
- net.ipv4.conf.default.rp_filter=0
- net.ipv4.conf.all.rp_filter=0
- net.ipv4.conf.eth0.rp_filter=0
- net.ipv4.conf.eth1.rp_filter=0
networks:
public0:
ipv4_address: 172.30.0.202
public1:
ipv4_address: 172.31.0.202
transactor:
image: mysteriumnetwork/transactor:0.1.0
environment:
PORT: 8888
expose:
- 8888
sysctls:
- net.ipv4.conf.default.rp_filter=0
- net.ipv4.conf.all.rp_filter=0
- net.ipv4.conf.eth0.rp_filter=0
- net.ipv4.conf.eth1.rp_filter=0
depends_on:
- ganache
command: >
-mystSCAddress 0xaa9c4e723609cb913430143fbc86d3cbe7adca21
-rpcEndpoint http://ganache:8545
-registry 0xbe180c8CA53F280C7BE8669596fF7939d933AA10
-ourIdentity 0x354bd098b4ef8c9e70b7f21be2d455df559705d7
-chImplementation 0x599d43715DF3070f83355D9D90AE62c159E62A75
-balanceCheckInterval 1s
volumes:
- ./e2e/blockchain/keystore:/keystore
dns: 172.30.0.254
networks:
public0:
ipv4_address: 172.30.0.203
public1:
ipv4_address: 172.31.0.203
hermes:
image: mysteriumnetwork/accountant:0.2
environment:
PORT: 8889
expose:
- 8889
sysctls:
- net.ipv4.conf.default.rp_filter=0
- net.ipv4.conf.all.rp_filter=0
- net.ipv4.conf.eth0.rp_filter=0
- net.ipv4.conf.eth1.rp_filter=0
depends_on:
- ganache
- mongodb
command: >
-identityPassphrase ""
-myst 0xaa9c4e723609cb913430143fbc86d3cbe7adca21
-rpcEndpoint http://ganache:8545
-registry 0xbe180c8CA53F280C7BE8669596fF7939d933AA10
-operator 0x354bd098b4ef8c9e70b7f21be2d455df559705d7
-chImplementation 0x599d43715DF3070f83355D9D90AE62c159E62A75
-keystoreDir /keystore
-hermesAddress 0x427c2bad22335710aec5e477f3e3adcd313a9bcb
-MongoUser hermes
-MongoPass hermes
-MongoHost "mongodb:27017"
-MongoReplSet ""
volumes:
- ./e2e/blockchain/keystore:/keystore
dns: 172.30.0.254
networks:
public0:
ipv4_address: 172.30.0.204
public1:
ipv4_address: 172.31.0.204
mongodb:
image: 'mongo:4.2.3'
environment:
- MONGO_INITDB_ROOT_PASSWORD=root
- MONGO_INITDB_ROOT_USERNAME=root
- MONGO_INITDB_DATABASE=hermes
- MONGO_NON_ROOT_USERNAME=hermes
- MONGO_NON_ROOT_PASSWORD=hermes
dns: 172.30.0.254
networks:
public0:
ipv4_address: 172.30.0.205
public1:
ipv4_address: 172.31.0.205
expose:
- 27017
- 27018
- 27019
volumes:
- ./e2e/mongo-init.e2e.js:/docker-entrypoint-initdb.d/mongo-init.js:ro
myst-consumer:
build:
context: .
dockerfile: ./localnet/node/Dockerfile
environment:
- DEFAULT_ROUTE=10.100.1.2
depends_on:
- forwarder
- broker
- mysterium-api
- ipify
- transactor
- hermes
- morqa
cap_add:
- NET_ADMIN
devices:
- /dev/net/tun
expose:
- 4050
volumes:
- ./localnet/volume/consumer:/var/lib/mysterium-node
- ./:/node
dns: 172.30.0.254
networks:
priv1:
ipv4_address: 10.100.1.101
myst-provider:
build:
context: .
dockerfile: ./localnet/node/Dockerfile
environment:
- DEFAULT_ROUTE=10.100.0.2
depends_on:
- forwarder2
- broker
- mysterium-api
- ipify
- transactor
- hermes
- morqa
cap_add:
- NET_ADMIN
devices:
- /dev/net/tun
expose:
- 1194
- 4050
volumes:
- ./localnet/volume/provider:/var/lib/mysterium-node
- ./:/node
dns: 172.31.0.254
networks:
priv0:
ipv4_address: 10.100.0.102
go-runner:
build:
context: .
dockerfile: ./e2e/gorunner/Dockerfile
volumes:
- ./:/node
- $GOPATH/pkg/mod:/go/pkg/mod
working_dir: /node
dns: 172.30.0.254
cap_add:
- NET_ADMIN
networks:
public0:
ipv4_address: 172.30.0.222
public1:
ipv4_address: 172.31.0.222
priv0:
ipv4_address: 10.100.0.222
priv1:
ipv4_address: 10.100.1.222
router:
build:
context: .
dockerfile: ./e2e/forwarder/Dockerfile
cap_add:
- NET_ADMIN
environment:
- EXT_NAT=172.30.0.1
networks:
public0:
ipv4_address: 172.30.0.254
public1:
ipv4_address: 172.31.0.254
forwarder:
build:
context: .
dockerfile: ./e2e/forwarder/Dockerfile
cap_add:
- NET_ADMIN
depends_on:
- router
environment:
- GATEWAY=172.30.0.254
networks:
public0:
ipv4_address: 172.30.0.2
priv1:
ipv4_address: 10.100.1.2
forwarder2:
build:
context: .
dockerfile: ./e2e/forwarder/Dockerfile
cap_add:
- NET_ADMIN
depends_on:
- router
environment:
- GATEWAY=172.31.0.254
dns: 172.31.0.254
networks:
public1:
ipv4_address: 172.31.0.2
priv0:
ipv4_address: 10.100.0.2
networks:
public0:
driver: "bridge"
ipam:
driver: default
config:
- subnet: 172.30.0.0/24
public1:
driver: "bridge"
ipam:
config:
- subnet: 172.31.0.0/24
priv0:
driver: "bridge"
ipam:
config:
- subnet: 10.100.0.0/24
priv1:
driver: "bridge"
ipam:
config:
- subnet: 10.100.1.0/24