Skip to content

Commit

Permalink
Add faucet account
Browse files Browse the repository at this point in the history
Creates a faucet account.
  • Loading branch information
Valentin Rodygin authored and karlb committed Dec 20, 2023
1 parent 7b62db1 commit 3846d12
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions core/celo_genesis.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ var (

FeeCurrencyAddr = common.HexToAddress("0xce16")
DevBalance, _ = new(big.Int).SetString("100000000000000000000", 10)
FaucetAddr = common.HexToAddress("0xfcf982bb4015852e706100b14e21f947a5bb718e")
)

func celoGenesisAccounts(fundedAddr common.Address) GenesisAlloc {
Expand Down Expand Up @@ -80,6 +81,10 @@ func celoGenesisAccounts(fundedAddr common.Address) GenesisAlloc {
var devBalance32 common.Hash
DevBalance.FillBytes(devBalance32[:])

faucetBalance, ok := new(big.Int).SetString("500000000000000000000000000", 10) // 500M
if !ok {
panic("Couldn not set faucet balance!")
}
return map[common.Address]GenesisAccount{
contracts.RegistryAddress: { // Registry Proxy
Code: proxyBytecode,
Expand Down Expand Up @@ -134,5 +139,8 @@ func celoGenesisAccounts(fundedAddr common.Address) GenesisAlloc {
DevAddr: {
Balance: DevBalance,
},
FaucetAddr: {
Balance: faucetBalance,
},
}
}

0 comments on commit 3846d12

Please sign in to comment.