Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ ops/l2-genesis/.devnet
ops/l2-genesis/.qanet
ops/l2-genesis/.testnet
ops/l2-genesis/.holesky
ops/l2-genesis/.mainnet
ops/l2-genesis/.morphtestnet
ops/devnet-morph/devnet/__pycache__
contracts/qanetL1.json
Expand Down
19 changes: 12 additions & 7 deletions ops/l2-genesis/deploy-config/mainnet-deploy-config.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,18 @@
"gasPriceOracleScalar": 1000000000,
"gasPriceOracleOwner": "0x2818a3aF785975a32611155A6eE36C21Cec068ca",

"govVotingDuration": 1000,
"recordOracleAddress": "0xefb531cd2fbebd784d5d49a7ad06c0200e0d169a",
"recordNextBatchSubmissionIndex": 1,

"govVotingDuration": 86400,
"govBatchBlockInterval": 600,
"govBatchMaxBytes": 124928,
"govBatchTimeout": 1200,
"govRollupEpoch": 600,
"govBatchMaxChunks": 45,
"l2SequencerAddresses": [
"govRollupEpoch": 7200,

"l2StakingSequencerMaxSize": 7,
"l2StakingUnDelegatedLockEpochs": 7,
"l2StakingRewardStartTime": 1764460800,
"l2StakingAddresses": [
"0x6ab0e960911b50f6d14f249782ac12ec3e7584a0",
"0xbba36cdf020788f0d08d5688c0bee3fb30ce1c80",
"0x34e387b37d3adeaa6d5b92ce30de3af3dca39796",
Expand All @@ -31,7 +36,7 @@
"0x61f2945d4bc9e40b66a6376d1094a50438f613e2",
"0xb6cf39ee72e0127e6ea6059e38b8c197227a6ac7"
],
"l2SequencerTmKeys": [
"l2StakingTmKeys": [
"0x2d7dcd2b93fcadef45fcdf65453118aa5d3efae27e3146d50464531b19fcafb4",
"0x4f2e0fba8a3fe709b0d9923e13b69924b90cb889f806d3cefe9a56d924f39839",
"0x89ded1a39b827b7a001fbb6fda9c26441b67bf0a586b8ee52236caf7d2a6ebca",
Expand All @@ -40,7 +45,7 @@
"0x77a1a01759de3b693ec1a8e6d083a05baca61a17faabb175449a63b708056c79",
"0x68ee3f9c25282c71d81e34d4188fc2514a41c97b8cb5d909cc78a624b1e27cba"
],
"l2SequencerBlsKeys": [
"l2StakingBlsKeys": [
"0x0000000000000000000000000000000012f51a5c0c73b62b6c8202fe87ad03bb3832d46b5bb40dd6b04d27e0c06fd88c1311f72e45a74f6086f85535e96c97db000000000000000000000000000000000f4718daff21bd38aa60e626321a2157e58a1735ed973925d1a4b621f48fa1c1a135f272213e3bc314fc93bd2a45818f0000000000000000000000000000000011701a778ffa03936d021e7df1c89236784e5b1b33fe9b4267d00a5fa72045065afeab3e17222c582d8e4d0070c1b7d7000000000000000000000000000000000d8ed30ff704b3e649243339f8413c6b3ae832f838b15b4a3a060a76166db54c71749ed04f5e7d6c198c80afee05779e",
"0x000000000000000000000000000000000d82cd3d4e3158a90a7108098e4fcaa610d7f89248ef55cfb76162e1ca17d14ba99b88ad79979007718d6e067c4b5d6b00000000000000000000000000000000011ab8cb6920caac25f2c8fb8f60627bb26aa34b9b4809c6f1e2bac4edcddb711bc9fd6c51be34e327218b98f7b35b5f000000000000000000000000000000001034b1945710226066ecffdc768032185322372c27fd4bf2c8a18da1c5f9847bec406e02844b4d33908bc754de0aadcc000000000000000000000000000000001950f84a7bd160796926fe6a680333c6438de1c4c09ca72a4bf23a49d417aa92c71c714d9292cf7417a0621372a55af7",
"0x0000000000000000000000000000000006f73bcdf4d37d9a8153a743f33b8fcb107f282a03ff4793c710ab349b1a71030367824cbe0c2ce332535567bae3f4380000000000000000000000000000000013429873d1c85c2b04c3d777448246c652b42cb3ee7d5e0babdaa811575e900d60a40f072ff4a6666427da742c10c0ee00000000000000000000000000000000191d6589871d0507ea3ed832859ae6f0ee08f534e98f5bae248ba56185ae2b73c0bd71ce61e68201b5a88798deb99a4b0000000000000000000000000000000000068bf679e513bf8ae98b810413e6eacb8d807a2d4d99cfdf5a763689b9b440304fa61f3ea38099a6159c85ff75d75c",
Expand Down
30 changes: 30 additions & 0 deletions ops/l2-genesis/mainnet-l2genesis.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
#!/bin/sh
set -eu

source ../../contracts/.env
MAINNET=".mainnet"
CONTRACT_CONFIG="../../contracts/src/deploy-config/mainnet.ts"
echo "Regenerating genesis files"
# Check if the folder exists
if [ ! -d "$MAINNET" ]; then
echo "Folder not exists, mkdir $MAINNET"
mkdir "$MAINNET"
fi

#if [[ -z "$RPC_URL" ]]; then
# the environment variable is missing, set a default value
# echo "RPC_URL is missing, using default value: http://qanet-l1"
RPC_URL="https://mainnet.infura.io/v3/b6bf7d3508c941499b10025c0776eaf8"
#fi
echo "RPC_URL is $RPC_URL"
cat "deploy-config/mainnet-deploy-config.json" > $MAINNET/mainnet-deploy-config.json
(
go run cmd/main.go genesis l2 \
--l1-rpc $RPC_URL \
--deploy-config $MAINNET/mainnet-deploy-config.json \
--deployment-dir "$PWD/../../contracts/mainnet.json" \
--outfile.l2 $MAINNET/genesis-l2.json \
--outfile.rollup $MAINNET/rollup.json \
--outfile.genbatchheader $MAINNET/genesis-batch-header.json
touch "$MAINNET/done"
)