make SCRIPT_PARAMS="--skipGoerliKey" testnet1

This commit is contained in:
Ștefan Talpalaru 2020-02-25 02:49:47 +01:00
parent e4ed51a144
commit 0b05fecedc
No known key found for this signature in database
GPG Key ID: CBF7934204F1B6F9
2 changed files with 7 additions and 4 deletions

View File

@ -130,10 +130,10 @@ clean-testnet1:
rm -rf build/data/testnet1
testnet0: | build deps
NIM_PARAMS="$(NIM_PARAMS)" LOG_LEVEL="$(LOG_LEVEL)" $(ENV_SCRIPT) nim $(NIM_PARAMS) scripts/connect_to_testnet.nims testnet0
NIM_PARAMS="$(NIM_PARAMS)" LOG_LEVEL="$(LOG_LEVEL)" $(ENV_SCRIPT) nim $(NIM_PARAMS) scripts/connect_to_testnet.nims $(SCRIPT_PARAMS) testnet0
testnet1: | build deps
NIM_PARAMS="$(NIM_PARAMS)" LOG_LEVEL="$(LOG_LEVEL)" $(ENV_SCRIPT) nim $(NIM_PARAMS) scripts/connect_to_testnet.nims testnet1
NIM_PARAMS="$(NIM_PARAMS)" LOG_LEVEL="$(LOG_LEVEL)" $(ENV_SCRIPT) nim $(NIM_PARAMS) scripts/connect_to_testnet.nims $(SCRIPT_PARAMS) testnet1
clean: | clean-common
rm -rf build/{$(TOOLS_CSV),all_tests,*_node,*ssz*,beacon_node_testnet*,state_sim,transition*}

View File

@ -23,7 +23,10 @@ proc validateTestnetName(parts: openarray[string]): auto =
quit 1
(parts[0], parts[1])
cli do (testnetName {.argument.}: string):
cli do (skipGoerliKey {.
desc: "Don't prompt for an Eth1 Goerli key to become a validator" .}: bool,
testnetName {.
argument .}: string):
let
nameParts = testnetName.split "/"
(team, testnet) = if nameParts.len > 1: validateTestnetName nameParts
@ -110,7 +113,7 @@ cli do (testnetName {.argument.}: string):
except OsError:
discard
if depositContractOpt.len > 0 and not system.dirExists(validatorsDir):
if not skipGoerliKey and depositContractOpt.len > 0 and not system.dirExists(validatorsDir):
mode = Silent
echo "\nPlease enter your Goerli Eth1 private key in hex form (e.g. 0x1a2...f3c) in order to become a validator (you'll need access to 32 GoETH)."
echo "Hit Enter to skip this."