-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add geth iliad config and data folder defaults #7
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -209,6 +209,8 @@ func getGenesisState(db ethdb.Database, blockhash common.Hash) (alloc types.Gene | |
genesis = DefaultSepoliaGenesisBlock() | ||
case params.HoleskyGenesisHash: | ||
genesis = DefaultHoleskyGenesisBlock() | ||
case params.IliadGenesisHash: | ||
genesis = DefaultIliadGenesisBlock() | ||
} | ||
if genesis != nil { | ||
return genesis.Alloc, nil | ||
|
@@ -409,6 +411,8 @@ func (g *Genesis) configOrDefault(ghash common.Hash) *params.ChainConfig { | |
return params.SepoliaChainConfig | ||
case ghash == params.GoerliGenesisHash: | ||
return params.GoerliChainConfig | ||
case ghash == params.IliadGenesisHash: | ||
return params.IliadChainConfig | ||
default: | ||
return params.AllEthashProtocolChanges | ||
} | ||
|
@@ -572,6 +576,18 @@ func DefaultHoleskyGenesisBlock() *Genesis { | |
} | ||
} | ||
|
||
// DefaultIliadGenesisBlock returns the iliad network genesis block. | ||
func DefaultIliadGenesisBlock() *Genesis { | ||
return &Genesis{ | ||
Config: params.IliadChainConfig, | ||
Difficulty: big.NewInt(0x20000), | ||
GasLimit: 0x7A1200, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. any impact of the gas limit at genesis? 8m |
||
Nonce: 0x42, | ||
Timestamp: 0, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. why 0? |
||
Alloc: decodePrealloc(iliadAllocData), | ||
} | ||
} | ||
|
||
// DeveloperGenesisBlock returns the 'geth --dev' genesis block. | ||
func DeveloperGenesisBlock(gasLimit uint64, faucet *common.Address) *Genesis { | ||
// Override the default period to the user requested one | ||
|
@@ -584,16 +600,17 @@ func DeveloperGenesisBlock(gasLimit uint64, faucet *common.Address) *Genesis { | |
BaseFee: big.NewInt(params.InitialBaseFee), | ||
Difficulty: big.NewInt(0), | ||
Alloc: map[common.Address]types.Account{ | ||
common.BytesToAddress([]byte{1}): {Balance: big.NewInt(1)}, // ECRecover | ||
common.BytesToAddress([]byte{2}): {Balance: big.NewInt(1)}, // SHA256 | ||
common.BytesToAddress([]byte{3}): {Balance: big.NewInt(1)}, // RIPEMD | ||
common.BytesToAddress([]byte{4}): {Balance: big.NewInt(1)}, // Identity | ||
common.BytesToAddress([]byte{5}): {Balance: big.NewInt(1)}, // ModExp | ||
common.BytesToAddress([]byte{6}): {Balance: big.NewInt(1)}, // ECAdd | ||
common.BytesToAddress([]byte{7}): {Balance: big.NewInt(1)}, // ECScalarMul | ||
common.BytesToAddress([]byte{8}): {Balance: big.NewInt(1)}, // ECPairing | ||
common.BytesToAddress([]byte{9}): {Balance: big.NewInt(1)}, // BLAKE2b | ||
common.BytesToAddress([]byte{1}): {Balance: big.NewInt(1)}, // ECRecover | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. nit, please remove the extra space to reduce the unnecessary changes. |
||
common.BytesToAddress([]byte{2}): {Balance: big.NewInt(1)}, // SHA256 | ||
common.BytesToAddress([]byte{3}): {Balance: big.NewInt(1)}, // RIPEMD | ||
common.BytesToAddress([]byte{4}): {Balance: big.NewInt(1)}, // Identity | ||
common.BytesToAddress([]byte{5}): {Balance: big.NewInt(1)}, // ModExp | ||
common.BytesToAddress([]byte{6}): {Balance: big.NewInt(1)}, // ECAdd | ||
common.BytesToAddress([]byte{7}): {Balance: big.NewInt(1)}, // ECScalarMul | ||
common.BytesToAddress([]byte{8}): {Balance: big.NewInt(1)}, // ECPairing | ||
common.BytesToAddress([]byte{9}): {Balance: big.NewInt(1)}, // BLAKE2b | ||
common.BytesToAddress([]byte{26}): {Balance: big.NewInt(1)}, // ipGraph | ||
|
||
// Pre-deploy EIP-4788 system contract | ||
params.BeaconRootsAddress: {Nonce: 1, Code: params.BeaconRootsCode, Balance: common.Big0}, | ||
}, | ||
|
Large diffs are not rendered by default.
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -47,6 +47,14 @@ var SepoliaBootnodes = []string{ | |
"enode://9e9492e2e8836114cc75f5b929784f4f46c324ad01daf87d956f98b3b6c5fcba95524d6e5cf9861dc96a2c8a171ea7105bb554a197455058de185fa870970c7c@138.68.123.152:30303", // sepolia-bootnode-1-ams3 | ||
} | ||
|
||
// IliadBootnodes are the enode URLs of the P2P bootstrap nodes running on the | ||
// Iliad test network. | ||
var IliadBootnodes = []string{ | ||
// Upstream bootnodes | ||
"enode://5e85033276299eff126d0c86a42b76cbad98920b4f77ae894b8a52daffa558f36de1281beca96b71e67795955bf769ce6ab3e35af66790816b37ada3d9c2b09a@52.9.220.233:30303", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. setup b1.testnet.storyrpc.io and b2.testnet.storyrpc.io |
||
"enode://7f7685f85a6cfbdb5342ef977ae9d1c82dae4fa8d0f3b141c0c1bb86a01bbc7ac081aa336ff9b341b751f756d388ac4eabbd810e548b52dfb835de0c844bd8b9@54.241.155.73:30303", | ||
} | ||
|
||
// GoerliBootnodes are the enode URLs of the P2P bootstrap nodes running on the | ||
// Görli test network. | ||
var GoerliBootnodes = []string{ | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
where is number coming from?