Skip to content

Commit 4beff8b

Browse files
authored
Merge pull request #637 from pinheadmz/fo-port
fork observer: get RPC ports dynamically for regtest/signet
2 parents 02ef87a + b3985bc commit 4beff8b

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src/warnet/deploy.py

+5-4
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
from .k8s import (
2626
get_default_namespace,
2727
get_default_namespace_or,
28+
get_mission,
2829
get_namespaces_by_type,
2930
wait_for_ingress_controller,
3031
wait_for_pod_ready,
@@ -181,15 +182,15 @@ def deploy_fork_observer(directory: Path, debug: bool) -> bool:
181182
override_string = ""
182183

183184
# Add an entry for each node in the graph
184-
for i, node in enumerate(network_file["nodes"]):
185-
node_name = node.get("name")
185+
for i, tank in enumerate(get_mission("tank")):
186+
node_name = tank.metadata.name
186187
node_config = f"""
187188
[[networks.nodes]]
188189
id = {i}
189190
name = "{node_name}"
190-
description = "A node. Just A node."
191+
description = ""
191192
rpc_host = "{node_name}.{default_namespace}.svc"
192-
rpc_port = 18443
193+
rpc_port = {int(tank.metadata.labels["RPCPort"])}
193194
rpc_user = "forkobserver"
194195
rpc_password = "tabconf2024"
195196
"""

0 commit comments

Comments
 (0)