Files
linea-monorepo/docker/config/l1-node/generate-genesis.sh
The Dark Jester 1b2040fe1e [Feat] Use 9 blobs for Pectra (#944)
* use 9 blobs for Pectra

* add linting to script

* turn prague on by default

* remove non-prague configuration

* testing not-yet-prague is the reason for failure

* using pectra from genesis

* reset to 9 for testing

* lowering blobs per tick

* add missing 9s and update blobscan

* spotless

* expect 9 blobs in one tx

* Update coordinator/app/src/main/kotlin/net/consensys/zkevm/coordinator/app/config/CoordinatorConfig.kt

Co-authored-by: Julien Marchand <julien-marchand@users.noreply.github.com>
Signed-off-by: The Dark Jester <thedarkjester@users.noreply.github.com>

* refactor testdata folders and use 9 blob agg

* refactor function for ease of reading

* move arguments up

* rename function

* format parameters

* validate at least 1 blob exists

* more spotless

* simplify blob hash computation

---------

Signed-off-by: The Dark Jester <thedarkjester@users.noreply.github.com>
Co-authored-by: Julien Marchand <julien-marchand@users.noreply.github.com>
2025-05-09 01:47:54 -07:00

25 lines
1.1 KiB
Bash
Executable File

# Script to modify config files to enable Prague/Electra to run for the local stack
# Runs on the 'l1-node-genesis-generator' Docker image entrypoint
original_el_genesis_json_path="/config/genesis.json"
original_cl_network_config_path="/config/network-config.yml"
output_dir="/data/l1-node-config"
modified_el_genesis_json_path=$output_dir/$(basename -- $original_el_genesis_json_path)
modified_cl_network_config_path=$output_dir/$(basename -- $original_cl_network_config_path)
mkdir -p $output_dir
cp $original_el_genesis_json_path $modified_el_genesis_json_path
cp $original_cl_network_config_path $modified_cl_network_config_path
# Although this adds 0s, it is here for flexibility in the event of extension and syntax issues.
OS=$(uname);
prague_time=$(
if [ $OS = "Linux" ]; then
date -d "+0 seconds" +%s;
elif [ $OS = "Darwin" ]; then
date -v +0S +%s;
fi
)
sed -i -E 's/"timestamp": "[0-9]+"/"timestamp": "'"$prague_time"'"/' $modified_el_genesis_json_path
sed -i 's/\$GENESIS_TIME/'"$prague_time"'/g' $modified_cl_network_config_path