From 7bd725c69f87bb63803fd371e7ae4ced881dec8a Mon Sep 17 00:00:00 2001 From: Roy Crihfield Date: Fri, 12 Jul 2024 17:06:09 +0800 Subject: [PATCH] CL spec: speed up validator withdrawals --- .../cerc-fixturenet-eth-lighthouse/genesis/cl/build_cl.sh | 5 +++++ .../cerc-fixturenet-eth-lighthouse/genesis/cl/vars.env | 7 +++++++ 2 files changed, 12 insertions(+) diff --git a/stack-orchestrator/container-build/cerc-fixturenet-eth-lighthouse/genesis/cl/build_cl.sh b/stack-orchestrator/container-build/cerc-fixturenet-eth-lighthouse/genesis/cl/build_cl.sh index 5157b38..1130cb7 100755 --- a/stack-orchestrator/container-build/cerc-fixturenet-eth-lighthouse/genesis/cl/build_cl.sh +++ b/stack-orchestrator/container-build/cerc-fixturenet-eth-lighthouse/genesis/cl/build_cl.sh @@ -44,6 +44,11 @@ lcli \ --interop-genesis-state \ --force +# Patch the spec with settings not supported by lcli +sed -i "/^SHARD_COMMITTEE_PERIOD:/s/:.*/: $SHARD_COMMITTEE_PERIOD/" $TESTNET_DIR/config.yaml +sed -i "/^MIN_VALIDATOR_WITHDRAWABILITY_DELAY:/s/:.*/: $MIN_VALIDATOR_WITHDRAWABILITY_DELAY/" $TESTNET_DIR/config.yaml +sed -i "/^MAX_SEED_LOOKAHEAD:/s/:.*/: $MAX_SEED_LOOKAHEAD/" $TESTNET_DIR/config.yaml + echo Specification and genesis.ssz generated at $TESTNET_DIR. echo "Generating $VALIDATOR_COUNT validators concurrently... (this may take a while)" diff --git a/stack-orchestrator/container-build/cerc-fixturenet-eth-lighthouse/genesis/cl/vars.env b/stack-orchestrator/container-build/cerc-fixturenet-eth-lighthouse/genesis/cl/vars.env index 54634fc..f790e4c 100644 --- a/stack-orchestrator/container-build/cerc-fixturenet-eth-lighthouse/genesis/cl/vars.env +++ b/stack-orchestrator/container-build/cerc-fixturenet-eth-lighthouse/genesis/cl/vars.env @@ -38,6 +38,13 @@ SECONDS_PER_SLOT=${SECONDS_PER_SLOT:-3} # Seconds per Eth1 block SECONDS_PER_ETH1_BLOCK=${SECONDS_PER_ETH1_BLOCK:-1} +# Min epochs between validator activation and exit +SHARD_COMMITTEE_PERIOD=2 +# Min epochs between validator exit and withdrawal +MIN_VALIDATOR_WITHDRAWABILITY_DELAY=1 +# Delay for validator activation/exit +MAX_SEED_LOOKAHEAD=1 + # Command line arguments for validator client VC_ARGS=${VC_ARGS:-""}