Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 11 additions & 6 deletions main.star
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,17 @@ def run(plan, args={}):
name="op_jwt_file",
)

# TODO We need to create the dependency sets before we launch the chains since
# e.g. op-node now depends on the artifacts to be present
#
# This can easily turn into another dependency cycle which means we might have to introduce yet another layer
# of execution whose sole purpose is to create required artifacts
for superchain_params in optimism_args.superchains:
superchain_launcher.launch(
plan=plan,
params=superchain_params,
)

l2s = []
for chain in optimism_args.chains:
# We filter out the supervisors applicable to this network
Expand Down Expand Up @@ -138,12 +149,6 @@ def run(plan, args={}):
)
)

for superchain_params in optimism_args.superchains:
superchain_launcher.launch(
plan=plan,
params=superchain_params,
)

for supervisor_params in optimism_args.supervisors:
op_supervisor_launcher.launch(
plan=plan,
Expand Down
16 changes: 14 additions & 2 deletions src/cl/op-node/op_node_launcher.star
Original file line number Diff line number Diff line change
Expand Up @@ -188,10 +188,19 @@ def get_beacon_config(
"--altda.da-server=" + da_server_context.http_url,
]

supervisor_params = _filter.first(supervisors_params)

# configure files

files = {
ethereum_package_constants.GENESIS_DATA_MOUNTPOINT_ON_CLIENTS: launcher.deployment_output,
ethereum_package_constants.GENESIS_DATA_MOUNTPOINT_ON_CLIENTS: Directory(
artifact_names=[
launcher.deployment_output,
supervisor_params.superchain.dependency_set.name,
]
)
if supervisor_params
else launcher.deployment_output,
ethereum_package_constants.JWT_MOUNTPOINT_ON_CLIENTS: launcher.jwt_file,
}

Expand Down Expand Up @@ -220,7 +229,6 @@ def get_beacon_config(

observability.expose_metrics_port(ports)

supervisor_params = _filter.first(supervisors_params)
if supervisor_params:
interop_rpc_port = supervisor_params.superchain.ports[
_net.INTEROP_RPC_PORT_NAME
Expand All @@ -232,6 +240,10 @@ def get_beacon_config(
"OP_NODE_INTEROP_RPC_ADDR": "0.0.0.0",
"OP_NODE_INTEROP_RPC_PORT": str(interop_rpc_port.number),
"OP_NODE_INTEROP_JWT_SECRET": ethereum_package_constants.JWT_MOUNT_PATH_ON_CONTAINER,
"OP_NODE_INTEROP_DEPENDENCY_SET": "{0}/{1}".format(
ethereum_package_constants.GENESIS_DATA_MOUNTPOINT_ON_CLIENTS,
supervisor_params.superchain.dependency_set.path,
),
}
)

Expand Down
1 change: 1 addition & 0 deletions test/el_cl_launcher_test.star
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,7 @@ def test_launch_with_superchains(plan):
"OP_NODE_INTEROP_RPC_ADDR": "0.0.0.0",
"OP_NODE_INTEROP_RPC_PORT": "9645",
"OP_NODE_INTEROP_JWT_SECRET": "/jwt/jwtsecret",
"OP_NODE_INTEROP_DEPENDENCY_SET": "/network-configs/superchain-depset-superchain0.json",
},
)
expect.eq(
Expand Down
Loading