Commit 27bef1e8 authored by Gyanendra Mishra's avatar Gyanendra Mishra

some more leg work

parent 59ce81d5
load("github.com/kurtosis-tech/eth2-merge-startosis-module/src/participant_network/prelaunch_data_generator/genesis_constants/genesis_constants.star", "pre_funded_accounts")
load("github.com/kurtosis-tech/eth2-merge-startosis-module/src/participant_network/prelaunch_data_generator/genesis_constants/genesis_constants.star", "PRE_FUNDED_ACCOUNTS")
def main():
print("This should work if CI is running correctly")
print(pre_funded_accounts)
\ No newline at end of file
print(PRE_FUNDED_ACCOUNTS)
\ No newline at end of file
# Needed to copy the JWT secret and the EL genesis.json file
EL_GENESIS_DIRPATH_ON_GENERATOR = "/el-genesis"
CONFIG_DIRPATH_ON_GENERATOR = "/config"
GENESIS_CONFIG_YML_FILENAME = "config.yaml" // WARNING: Do not change this! It will get copied to the CL genesis data, and the CL clients are hardcoded to look for this filename
MNEMONICS_YML_FILENAME = "mnemonics.yaml"
OUTPUT_DIRPATH_ON_GENERATOR = "/output"
TRANCHES_DIRANME = "tranches"
GENESIS_STATE_FILENAME = "genesis.ssz"
DEPLOY_BLOCK_FILENAME = "deploy_block.txt"
DEPOSIT_CONTRACT_FILENAME = "deposit_contract.txt"
# Generation constants
CL_GENESIS_GENERATION_BINARY_FILEPATH_ON_CONTAINER = "/usr/local/bin/eth2-testnet-genesis"
DEPLOY_BLOCK = "0"
ETH1_BLOCK = "0x0000000000000000000000000000000000000000000000000000000000000000"
SUCCESSFUL_EXEC_CMD_EXIT_CODE = 0
def generate_cl_genesis_data(
genesis_generation_config_yml_template,
genesis_generation_mnemonics_yml_template,
el_genesis_data.ELGenesisData,
genesis_unix_timestamp,
network_id,
deposit_contract_address,
seconds_per_slot,
preregistered_validator_keys_mnemonic,
total_num_validator_keys_to_preregister):
template_data = new_cl_genesis_config_template_data{
network_id,
seconds_per_slot,
genesis_unix_timestamp,
total_num_validator_keys_to_preregister,
preregistered_validator_keys_mnemonic,
deposit_contract_address,
}
def new_cl_genesis_config_template_data(network_id, seconds_per_slot, unix_timestamp, total_terminal_difficulty, altair_fork_epoch, merge_fork_epoch, num_validator_keys_to_preregister, preregistered_validator_keys_mnemonic, deposit_contract_address):
return {
"NetworkId": network_id,
"SecondsPerSlot": seconds_per_slot,
"UnixTimestamp": unix_timestamp,
"TotalTerminalDifficulty": total_terminal_difficulty,
"AltairForkEpoch": altair_fork_epoch,
"MergeForkEpoch": merge_fork_epoch,
"NumValidatorKeysToPreregister": num_validator_keys_to_preregister,
"PreregisteredValidatorKeysMnemonic": preregistered_validator_keys_mnemonic,
"DepositContractAddress": deposit_contract_address,
}
......@@ -5,7 +5,7 @@ def new_prefunded_account(address, private_key) :
# 1) Installing Wagyu: https://github.com/AleoHQ/wagyu
# 2) Running `wagyu ethereum import-hd -m MNEMONIC_FROM_GENESIS -d PREFUNDED_ACCOUNT_DERIVATION_PATH`
# 3) Copying the outputted information
pre_funded_accounts = [
PRE_FUNDED_ACCOUNTS = [
# UTC--2021-12-22T19-14-08.590377700Z--878705ba3f8bc32fcf7f4caa1a35e72af65cf766
# m/44'/60'/0'/0/0
new_prefunded_account(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment