Commit 5db8adf0 authored by Barnabas Busa's avatar Barnabas Busa Committed by GitHub

feat: enable customization of L1/L2 chain info (#10730)

* feat: enable customization of L1/L2 chain info

* add faultGameWithdrawalDelay

* Update config.sh
parent 1595335c
...@@ -18,6 +18,19 @@ export GS_PROPOSER_PRIVATE_KEY= ...@@ -18,6 +18,19 @@ export GS_PROPOSER_PRIVATE_KEY=
export GS_SEQUENCER_ADDRESS= export GS_SEQUENCER_ADDRESS=
export GS_SEQUENCER_PRIVATE_KEY= export GS_SEQUENCER_PRIVATE_KEY=
##################################################
# Chain Information #
##################################################
# L1 chain information
export L1_CHAIN_ID=11155111
export L1_BLOCK_TIME=12
# L2 chain information
export L2_CHAIN_ID=42069
export L2_BLOCK_TIME=2
################################################## ##################################################
# op-node Configuration # # op-node Configuration #
################################################## ##################################################
......
...@@ -18,6 +18,10 @@ reqenv "GS_BATCHER_ADDRESS" ...@@ -18,6 +18,10 @@ reqenv "GS_BATCHER_ADDRESS"
reqenv "GS_PROPOSER_ADDRESS" reqenv "GS_PROPOSER_ADDRESS"
reqenv "GS_SEQUENCER_ADDRESS" reqenv "GS_SEQUENCER_ADDRESS"
reqenv "L1_RPC_URL" reqenv "L1_RPC_URL"
reqenv "L1_CHAIN_ID"
reqenv "L2_CHAIN_ID"
reqenv "L1_BLOCK_TIME"
reqenv "L2_BLOCK_TIME"
# Get the finalized block timestamp and hash # Get the finalized block timestamp and hash
block=$(cast block finalized --rpc-url "$L1_RPC_URL") block=$(cast block finalized --rpc-url "$L1_RPC_URL")
...@@ -29,10 +33,10 @@ config=$(cat << EOL ...@@ -29,10 +33,10 @@ config=$(cat << EOL
{ {
"l1StartingBlockTag": "$blockhash", "l1StartingBlockTag": "$blockhash",
"l1ChainID": 11155111, "l1ChainID": $L1_CHAIN_ID,
"l2ChainID": 42069, "l2ChainID": $L2_CHAIN_ID,
"l2BlockTime": 2, "l2BlockTime": $L2_BLOCK_TIME,
"l1BlockTime": 12, "l1BlockTime": $L1_BLOCK_TIME,
"maxSequencerDrift": 600, "maxSequencerDrift": 600,
"sequencerWindowSize": 3600, "sequencerWindowSize": 3600,
...@@ -97,6 +101,7 @@ config=$(cat << EOL ...@@ -97,6 +101,7 @@ config=$(cat << EOL
"faultGameGenesisBlock": 0, "faultGameGenesisBlock": 0,
"faultGameGenesisOutputRoot": "0x0000000000000000000000000000000000000000000000000000000000000000", "faultGameGenesisOutputRoot": "0x0000000000000000000000000000000000000000000000000000000000000000",
"faultGameSplitDepth": 14, "faultGameSplitDepth": 14,
"faultGameWithdrawalDelay": 604800,
"preimageOracleMinProposalSize": 1800000, "preimageOracleMinProposalSize": 1800000,
"preimageOracleChallengePeriod": 86400 "preimageOracleChallengePeriod": 86400
......
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