Skip to content

Commit 84bc53d

Browse files
committed
Make the simulator-cl advertise docker ip/port for builder-playground
1 parent dd569a1 commit 84bc53d

File tree

3 files changed

+15
-11
lines changed

3 files changed

+15
-11
lines changed

docker/simulator/.env.playground

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,10 @@ OP_NODE_P2P_LISTEN_IP=0.0.0.0
3939
OP_NODE_P2P_LISTEN_TCP_PORT=9222
4040
OP_NODE_P2P_LISTEN_UDP_PORT=9222
4141
OP_NODE_INTERNAL_IP="true"
42+
OP_NODE_P2P_ADVERTISE_IP=host.docker.internal
43+
OP_NODE_P2P_ADVERTISE_TCP=19222
44+
OP_NODE_P2P_ADVERTISE_UDP=19222
4245

43-
# RETH CONFIGURATION
44-
# ----------------
45-
OP_RETH_DISABLE_DISCOVERY="false"
46-
OP_RETH_DISABLE_TX_POOL_GOSSIP="true"
4746

4847
# RPC CONFIGURATION
4948
# ---------------
@@ -52,7 +51,7 @@ OP_NODE_RPC_PORT=8545
5251

5352
# LOGGING & MONITORING
5453
# ------------------
55-
OP_NODE_LOG_LEVEL=info
54+
OP_NODE_LOG_LEVEL=debug
5655
OP_NODE_LOG_FORMAT="json"
5756
OP_NODE_SNAPSHOT_LOG=/tmp/op-node-snapshot-log
5857
OP_NODE_METRICS_ENABLED="true"

docker/simulator/docker-compose.yml

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,17 @@ services:
1313
- bash
1414
- -c
1515
- |
16-
OP_NODE_L2_ENGINE_AUTH_RAW=$(cat /data/jwtsecret)
17-
OP_NODE_P2P_BOOTNODES=$(grep 'enr=' /artifacts/logs/op-node.log | sed -n 's/.*enr=\([^ ]*\).*/\1/p')
18-
export OP_NODE_L2_ENGINE_AUTH_RAW OP_NODE_P2P_BOOTNODES
19-
exec ./op-node-entrypoint
16+
echo "Writing JWT secret to $${OP_NODE_L2_ENGINE_AUTH}"
17+
cat /data/jwtsecret > "$${OP_NODE_L2_ENGINE_AUTH}"
18+
export OP_NODE_P2P_BOOTNODES=$(grep 'enr=' /artifacts/logs/op-node.log | sed -n 's/.*enr=\([^ ]*\).*/\1/p')
19+
eval "OP_NODE_L2_ENGINE_HTTP=\$${OP_NODE_L2_ENGINE_RPC/ws/http}"
20+
until [ "$(curl -s -w '%{http_code}' -o /dev/null "$${OP_NODE_L2_ENGINE_HTTP}")" -eq 401 ]; do
21+
echo "waiting for execution client to be ready"
22+
sleep 5
23+
done
24+
exec ./op-node
2025
volumes:
21-
- ~/.playground/devnet/:/artifacts
26+
- ~/.playground/devnet:/artifacts
2227
- ~/.playground/devnet/jwtsecret:/data/jwtsecret
2328
- ~/.playground/devnet/rollup.json:/data/rollup.json
2429
env_file:

justfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ simulator:
9393
cargo run --bin tips-simulator node
9494

9595
simulator-playground:
96-
cargo run --bin tips-simulator node --builder.playground --datadir ~/.playground/devnet/tips-simulator --authrpc.port=8554
96+
RUST_LOG=debug cargo run --bin tips-simulator node --builder.playground --datadir ~/.playground/devnet/tips-simulator --authrpc.port=8554
9797

9898
ui:
9999
cd ui && yarn dev

0 commit comments

Comments
 (0)