forked from celestiaorg/optimism
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
268 lines (255 loc) · 8.47 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
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
version: '3.4'
# This Compose file is expected to be used with the devnet-up.sh script.
# The volumes below mount the configs generated by the script into each
# service.
volumes:
l1_data:
l2_data:
da_data:
op_log:
services:
op_stack_go_builder: # Not an actual service, but builds the prerequisite go images
build:
context: ../
dockerfile: ops/docker/op-stack-go/Dockerfile
args:
GIT_COMMIT: "dev"
GIT_DATE: "0"
image: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:devnet
entrypoint: ["echo", "build complete"]
da:
image: ghcr.io/rollkit/local-celestia-devnet:v0.13.1
ports:
- "26658:26658"
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:26659/header/1"]
interval: 10s
timeout: 5s
retries: 5
start_period: 30s
l1:
build:
context: .
dockerfile: Dockerfile.l1
ports:
- "8545:8545"
- "8546:8546"
- "7060:6060"
volumes:
- "l1_data:/db"
- "${PWD}/../.devnet/genesis-l1.json:/genesis.json"
- "${PWD}/test-jwt-secret.txt:/config/test-jwt-secret.txt"
environment:
GETH_MINER_RECOMMIT: 100ms
l2:
build:
context: .
dockerfile: Dockerfile.l2
ports:
- "9545:8545"
- "8060:6060"
volumes:
- "l2_data:/db"
- "${PWD}/../.devnet/genesis-l2.json:/genesis.json"
- "${PWD}/test-jwt-secret.txt:/config/test-jwt-secret.txt"
entrypoint: # pass the L2 specific flags by overriding the entry-point and adding extra arguments
- "/bin/sh"
- "/entrypoint.sh"
- "--authrpc.jwtsecret=/config/test-jwt-secret.txt"
environment:
GETH_MINER_RECOMMIT: 100ms
op-node:
depends_on:
- op_stack_go_builder
- l1
- l2
- da
build:
context: ../
dockerfile: ./op-node/Dockerfile
args:
OP_STACK_GO_BUILDER: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:devnet
image: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-node:devnet
command: >
op-node
--l1=ws://l1:8546
--l1.beacon.ignore
--l2=http://l2:8551
--l2.jwt-secret=/config/test-jwt-secret.txt
--sequencer.enabled
--sequencer.l1-confs=0
--verifier.l1-confs=0
--p2p.sequencer.key=8b3a350cf5c34c9194ca85829a2df0ec3153be0318b5e2d3348e872092edffba
--rollup.config=/rollup.json
--rpc.addr=0.0.0.0
--rpc.port=8545
--p2p.listen.ip=0.0.0.0
--p2p.listen.tcp=9003
--p2p.listen.udp=9003
--p2p.scoring.peers=light
--p2p.ban.peers=true
--snapshotlog.file=/op_log/snapshot.log
--p2p.priv.path=/config/p2p-node-key.txt
--metrics.enabled
--metrics.addr=0.0.0.0
--metrics.port=7300
--pprof.enabled
--rpc.enable-admin
environment:
OP_NODE_DA_RPC: "http://da:26658"
OP_NODE_DA_AUTH_TOKEN: "${CELESTIA_NODE_AUTH_TOKEN}"
OP_NODE_DA_NAMESPACE: "00000000000000000000000000000000000000000008e5f679bf7116cb"
ports:
- "7545:8545"
- "9003:9003"
- "7300:7300"
- "6060:6060"
volumes:
- "${PWD}/p2p-sequencer-key.txt:/config/p2p-sequencer-key.txt"
- "${PWD}/p2p-node-key.txt:/config/p2p-node-key.txt"
- "${PWD}/test-jwt-secret.txt:/config/test-jwt-secret.txt"
- "${PWD}/../.devnet/rollup.json:/rollup.json"
- op_log:/op_log
op-proposer:
depends_on:
- op_stack_go_builder
- l1
- l2
- op-node
build:
context: ../
dockerfile: ./op-proposer/Dockerfile
args:
OP_STACK_GO_BUILDER: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:devnet
image: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-proposer:devnet
ports:
- "6062:6060"
- "7302:7300"
- "6546:8545"
environment:
OP_PROPOSER_L1_ETH_RPC: http://l1:8545
OP_PROPOSER_ROLLUP_RPC: http://op-node:8545
OP_PROPOSER_POLL_INTERVAL: 1s
OP_PROPOSER_NUM_CONFIRMATIONS: 1
OP_PROPOSER_MNEMONIC: test test test test test test test test test test test junk
OP_PROPOSER_L2_OUTPUT_HD_PATH: "m/44'/60'/0'/0/1"
OP_PROPOSER_L2OO_ADDRESS: "${L2OO_ADDRESS}"
OP_PROPOSER_GAME_FACTORY_ADDRESS: "${DGF_ADDRESS}"
OP_PROPOSER_GAME_TYPE: "${DG_TYPE}"
OP_PROPOSER_PROPOSAL_INTERVAL: "${PROPOSAL_INTERVAL}"
OP_PROPOSER_PPROF_ENABLED: "true"
OP_PROPOSER_METRICS_ENABLED: "true"
OP_PROPOSER_ALLOW_NON_FINALIZED: "true"
OP_PROPOSER_RPC_ENABLE_ADMIN: "true"
op-batcher:
depends_on:
op_stack_go_builder:
condition: service_started
l1:
condition: service_started
l2:
condition: service_started
op-node:
condition: service_started
da:
condition: service_healthy
build:
context: ../
dockerfile: ./op-batcher/Dockerfile
args:
OP_STACK_GO_BUILDER: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:devnet
image: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-batcher:devnet
ports:
- "6061:6060"
- "7301:7300"
- "6545:8545"
environment:
OP_BATCHER_L1_ETH_RPC: http://l1:8545
OP_BATCHER_L2_ETH_RPC: http://l2:8545
OP_BATCHER_ROLLUP_RPC: http://op-node:8545
OFFLINE_GAS_ESTIMATION: null
OP_BATCHER_MAX_CHANNEL_DURATION: 1
OP_BATCHER_SUB_SAFETY_MARGIN: 4 # SWS is 15, ChannelTimeout is 40
OP_BATCHER_POLL_INTERVAL: 1s
OP_BATCHER_NUM_CONFIRMATIONS: 1
OP_BATCHER_MNEMONIC: test test test test test test test test test test test junk
OP_BATCHER_SEQUENCER_HD_PATH: "m/44'/60'/0'/0/2"
OP_BATCHER_PPROF_ENABLED: "true"
OP_BATCHER_METRICS_ENABLED: "true"
OP_BATCHER_RPC_ENABLE_ADMIN: "true"
OP_BATCHER_BATCH_TYPE: 0
OP_BATCHER_DA_RPC: "http://da:26658"
OP_BATCHER_DA_AUTH_TOKEN: "${CELESTIA_NODE_AUTH_TOKEN}"
OP_BATCHER_DA_NAMESPACE: "00000000000000000000000000000000000000000008e5f679bf7116cb"
op-challenger:
depends_on:
- op_stack_go_builder
- l1
- l2
- op-node
build:
context: ../
dockerfile: ./op-challenger/Dockerfile
args:
OP_STACK_GO_BUILDER: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:devnet
image: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-challenger:devnet
volumes:
- "../op-program/bin:/op-program"
environment:
OP_CHALLENGER_L1_ETH_RPC: http://l1:8545
# Note: this will need to be updated to point to a L1 consensus node when there is one in the devnet
OP_CHALLENGER_L1_BEACON: "unset"
OP_CHALLENGER_ROLLUP_RPC: http://op-node:8545
OP_CHALLENGER_TRACE_TYPE: cannon
OP_CHALLENGER_GAME_FACTORY_ADDRESS: ${DGF_ADDRESS}
# The devnet can't set the absolute prestate output root because the contracts are deployed in L1 genesis
# before the L2 genesis is known.
OP_CHALLENGER_UNSAFE_ALLOW_INVALID_PRESTATE: "true"
OP_CHALLENGER_DATADIR: temp/challenger-data
OP_CHALLENGER_CANNON_ROLLUP_CONFIG: ./.devnet/rollup.json
OP_CHALLENGER_CANNON_L2_GENESIS: ./.devnet/genesis-l2.json
OP_CHALLENGER_CANNON_BIN: ./cannon/bin/cannon
OP_CHALLENGER_CANNON_SERVER: /op-program/op-program
OP_CHALLENGER_CANNON_PRESTATE: /op-program/prestate.json
OP_CHALLENGER_CANNON_L2: http://l2:8545
OP_CHALLENGER_MNEMONIC: test test test test test test test test test test test junk
OP_CHALLENGER_HD_PATH: "m/44'/60'/0'/0/4"
OP_CHALLENGER_NUM_CONFIRMATIONS: 1
da-server:
image: us-docker.pkg.dev/oplabs-tools-artifacts/images/da-server:devnet
build:
context: ../
dockerfile: ./op-plasma/Dockerfile
command: >
da-server
--file.path=/data
--addr=0.0.0.0
--port=3100
--log.level=debug
ports:
- "3100:3100"
volumes:
- "da_data:/data"
sentinel:
image: quarry/sentinel # TODO(10141): We need a public image for this (sentinel is out of repo)
volumes:
- "${PWD}/../.devnet/rollup.json:/rollup.json"
# private-key is mnemonic index 5 of the test mnemonic.
command: >
sentinel
--datadir=data
--l1-rpc-http=http://l1:8545
--l1-rpc-ws=ws://l1:8546
--da-storage-uri=http://da-server:3100
--private-key=0x8b3a350cf5c34c9194ca85829a2df0ec3153be0318b5e2d3348e872092edffba
--config=/rollup.json
artifact-server:
depends_on:
- l1
image: nginx:1.25-alpine
ports:
- "8080:80"
volumes:
- "${PWD}/../.devnet/:/usr/share/nginx/html/:ro"
security_opt:
- "no-new-privileges:true"