forked from bandprotocol/bandchain
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yaml
141 lines (127 loc) · 3.41 KB
/
docker-compose.yaml
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
version: "3.7"
services:
multi-validator1-node:
build:
context: .
dockerfile: chain/Dockerfile
image: band-validator:latest
networks:
bandchain:
ipv4_address: 172.18.0.11
command: sh -c "chmod +x ./run.sh && ./run.sh validator1"
multi-validator2-node:
image: band-validator:latest
networks:
bandchain:
ipv4_address: 172.18.0.12
command: sh -c "chmod +x ./run.sh && ./run.sh validator2"
multi-validator3-node:
image: band-validator:latest
networks:
bandchain:
ipv4_address: 172.18.0.13
command: sh -c "chmod +x ./run.sh && ./run.sh validator3"
multi-validator4-node:
image: band-validator:latest
networks:
bandchain:
ipv4_address: 172.18.0.14
command: sh -c "chmod +x ./run.sh && ./run.sh validator4"
emitter-node:
image: band-validator:latest
networks:
bandchain:
command: sh -c "chmod +x ./run.sh && ./run.sh emitter"
query-node:
image: band-validator:latest
ports:
- 26657:26657
networks:
bandchain:
ipv4_address: 172.18.0.15
command: sh -c "chmod +x ./run.sh && ./run.sh query-node"
rest-server:
image: band-validator:latest
networks:
bandchain:
ipv4_address: 172.18.0.20
restart: always
ports:
- 1317:1317
command: bandcli rest-server --laddr tcp://0.0.0.0:1317 --node tcp://172.18.0.15:26657 --chain-id bandchain --trust-node
proxy-server:
build:
context: scan/proxy
image: proxy-server:latest
networks:
bandchain:
ipv4_address: 172.18.0.99
depends_on:
- rest-server
ports:
- 80:80
postgres:
image: postgres:12
restart: always
networks:
bandchain:
ipv4_address: 172.18.0.88
environment:
POSTGRES_PASSWORD: postgrespassword
graphql-engine:
image: hasura/graphql-engine:v1.1.0
ports:
- "5433:5433"
depends_on:
- "postgres"
restart: always
networks:
bandchain:
ipv4_address: 172.18.0.89
environment:
HASURA_GRAPHQL_DATABASE_URL: postgres://postgres:[email protected]:5432/postgres
HASURA_GRAPHQL_ENABLE_CONSOLE: "true"
HASURA_GRAPHQL_ENABLED_LOG_TYPES: startup, http-log, webhook-log, websocket-log, query-log
HASURA_GRAPHQL_SERVER_HOST: 0.0.0.0
HASURA_GRAPHQL_SERVER_PORT: 5433
HASURA_GRAPHQL_STRINGIFY_NUMERIC_TYPES: "true"
# TODO: Expose port to consume kafka from other
zookeeper:
image: wurstmeister/zookeeper
# ports:
# - "2181:2181"
networks:
bandchain:
ipv4_address: 172.18.0.30
kafka:
image: wurstmeister/kafka
# ports:
# - "9092:9092"
networks:
bandchain:
ipv4_address: 172.18.0.31
environment:
KAFKA_ADVERTISED_HOST_NAME: 172.18.0.31
KAFKA_ADVERTISED_PORT: 9092
KAFKA_CREATE_TOPICS: test:1:1
KAFKA_ZOOKEEPER_CONNECT: 172.18.0.30:2181
volumes:
- /var/run/docker.sock:/var/run/docker.sock
flusher-init:
build:
context: flusher
image: bandchain_flusher:latest
networks:
bandchain:
command: sh -c "sleep 30 && python main.py init bandchain test --db postgres:[email protected]:5432/postgres"
flusher-daemon:
image: bandchain_flusher:latest
networks:
bandchain:
restart: always
networks:
bandchain:
ipam:
driver: default
config:
- subnet: "172.18.0.0/16"