-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathdocker-compose.dev.yml
executable file
·226 lines (215 loc) · 6.12 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
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
version: "3"
services:
db_postgres:
container_name: "db_boilerplate"
image: "postgres:12.6-alpine"
restart: always
healthcheck:
test: "pg_isready -U walter -d postgres"
interval: 5s
timeout: 15s
retries: 5
env_file:
- .env
ports:
- "5433:5432"
command: ["postgres", "-cshared_preload_libraries=pg_stat_statements"]
volumes:
- ./local-data/database/boilerplate:/var/lib/postgresql/data/
environment:
POSTGRES_INITDB_ARGS: "--encoding=UTF-8 --lc-collate=C --lc-ctype=C"
POSTGRES_PASSWORD: "white"
desci_blockchain_ganache:
container_name: "desci_blockchain_ganache"
build: ./desci-contracts
restart: always
healthcheck:
test: curl -sf -X POST --data '{"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id":1}' localhost:8545
interval: 10s
timeout: 15s
retries: 10
ports:
- "8545:8545"
env_file:
- .env
extra_hosts:
- host.docker.internal:host-gateway
volumes:
- ./local-data/ganache:/data
- ./desci-contracts/.openzeppelin:/app/.openzeppelin
depends_on:
graph_node:
condition: service_started
db_postgres:
condition: service_healthy
desci_nodes_backend:
container_name: "desci_nodes_backend"
entrypoint: /bin/sh './desci-server/scripts/be-node-dev.sh'
env_file:
- .env
ports:
- "5420:5420"
- "9229:9229"
- "9277:9277"
- "5555:5555"
extra_hosts:
- host.docker.internal:host-gateway
depends_on:
db_postgres:
condition: service_healthy
desci_blockchain_ganache:
condition: service_healthy
graph_node:
condition: service_started
redis:
condition: service_started
# - nodes_media # UNCOMMENT FOR LOCAL DEV OF nodes-media
links:
- db_postgres
volumes:
- ./local-data/yarn_cache:/root/.yarn
# mem_limit: 2g #uncomment to test large data with limited memory
block_explorer_dev:
image: sinaiman/expedition-dev:latest
container_name: "block_explorer"
ports:
- "3001:80"
graph_node:
image: graphprotocol/graph-node
container_name: "graph_node"
restart: always
# healthcheck:
# test: "pg_isready -U walter -d postgres"
# interval: 5s
# timeout: 15s
# retries: 5
ports:
- "8000:8000"
- "8001:8001"
- "8020:8020"
- "8030:8030"
- "8040:8040"
extra_hosts:
- host.docker.internal:host-gateway
depends_on:
ipfs:
condition: service_healthy
db_postgres:
condition: service_healthy
environment:
# https://github.com/graphprotocol/graph-node/blob/master/docs/environment-variables.md
postgres_host: db_postgres
# postgres_port: 5433
postgres_user: walter
postgres_pass: white
postgres_db: postgres
ipfs: "host.docker.internal:5001"
ethereum: "ganache:http://host.docker.internal:8545"
# see levels here https://docs.rs/env_logger/0.6.0/env_logger/
GRAPH_LOG: info
RUST_BACKTRACE: 1
GRAPH_MAPPING_HANDLER_TIMEOUT: 10
# GRAPH_ETHEREUM_FETCH_TXN_RECEIPTS_IN_BATCHES: true
GRAPH_IPFS_TIMEOUT: 10
# ENABLE_GRAPHQL_VALIDATIONS: true
# GRAPH_QUERY_CACHE_BLOCKS: 0
# GRAPH_LOG_POI_EVENTS: true
# GRAPH_LOAD_THRESHOLD: 250
# EXPERIMENTAL_SUBGRAPH_VERSION_SWITCHING_MODE: synced
ipfs:
image: ipfs/kubo:v0.24.0
container_name: "ipfs"
environment:
IPFS_SWARM_KEY: "/key/swarm/psk/1.0.0/\n/base16/\n9d002c50635a479d29dcc0ccb49d862952a0dcc52baddd253167adcd496c8d04"
ports:
- "5001:5001"
- "8089:8080"
command:
# These are defaults from the go-ipfs dockerfile CMD
- "daemon"
- "--migrate=true"
- "--agent-version-suffix=docker"
# This is necessary before ceramic ships Recon, the new tip gossip protocol
- "--enable-pubsub-experiment"
extra_hosts:
- host.docker.internal:host-gateway
volumes:
- ./local-data/ipfs:/data/ipfs
healthcheck:
test: ipfs ls QmUNLLsPACCz1vLxQVkXqqLX5R1X345qqfHbsf67hvA3Nn || exit 1
interval: 5s
retries: 5
start_period: 10s
timeout: 2s
ipfs_public:
image: ipfs/kubo:v0.24.0
container_name: "ipfs_public"
ports:
- "5002:5001"
- "8090:8080"
command:
# These are defaults from the go-ipfs dockerfile CMD
- "daemon"
- "--migrate=true"
- "--agent-version-suffix=docker"
# This is necessary before ceramic ships Recon, the new tip gossip protocol
- "--enable-pubsub-experiment"
extra_hosts:
- host.docker.internal:host-gateway
volumes:
- ./local-data/ipfs_public:/data/ipfs
healthcheck:
test: ipfs ls QmUNLLsPACCz1vLxQVkXqqLX5R1X345qqfHbsf67hvA3Nn || exit 1
interval: 5s
retries: 5
start_period: 10s
timeout: 2s
redis:
image: "redis:7-alpine"
container_name: "redis_cache"
ports:
- "6379:6379"
volumes:
- ./local-data/redis:/data
ceramic:
image: ceramicnetwork/js-ceramic:5.3.0
container_name: ceramic
ports:
- "7007:7007"
environment:
NODE_ENV: production
extra_hosts:
- host.docker.internal:host-gateway
volumes:
- ./local-data/ceramic/statestore:/root/.ceramic/statestore
- ./.ceramicDev.config.json:/root/.ceramic/daemon.config.json
depends_on:
ipfs:
condition: service_healthy
db_postgres:
condition: service_healthy
desci-media-isolated:
build:
context: ./desci-media-isolated
target: dev
container_name: "media_isolated"
volumes:
- ./desci-media-isolated:/usr/src/app
ports:
- "9777:9777" # debugger
# - "7771:7771" # Uncomment if you want to test the media server from the host machine
# desci_nodes_backend_test:
# container_name: 'be_test_boilerplate'
# command: echo 'Test container ready'
# build: .
# stdin_open: true
# tty: true
# depends_on:
# - db_postgres
# links:
# - db_postgres
# env_file:
# - .envs
# volumes:
# - .:/app/
# - /app/node_modules