-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathmain.star
More file actions
38 lines (34 loc) · 1.22 KB
/
main.star
File metadata and controls
38 lines (34 loc) · 1.22 KB
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
# Sacristy is Ethereum testnet infrastructure for Sigil development.
#
# This is the root dispatcher that routes to -modules based on the target arg.
#
# Usage:
# kurtosis run . --enclave sacristy
# kurtosis run . --enclave sacristy '{"target": "l1"}'
# kurtosis run . --enclave sacristy '{"target": "l1-bootstrap"}'
# kurtosis run . --enclave sacristy '{"target": "l2"}'
#
# Or use the Makefile:
# make l1 # Deploy L1
# make l1-bootstrap # Run L1 bootstrap
# make l2 # Deploy L2
l1_module = import_module("./l1/main.star")
l1_bootstrap_module = import_module("./l1-bootstrap/main.star")
l2_module = import_module("./l2/main.star")
def run(plan, args={}):
"""
Dispatch to the appropriate sub-module based on target.
Args:
plan: Kurtosis plan.
args: Configuration with optional "target" key.
Valid targets: "l1" (default), "l1-bootstrap", "l2"
"""
target = args.get("target", "l1")
if target == "l1":
return l1_module.run(plan, args)
elif target == "l1-bootstrap":
return l1_bootstrap_module.run(plan, args)
elif target == "l2":
return l2_module.run(plan, args)
else:
fail("Unknown target: '{}'.".format(target))