From 90219ab8da16a672ffb2d123f9fa226dc4e6f6c3 Mon Sep 17 00:00:00 2001 From: Sebastian <379651+czarly@users.noreply.github.com> Date: Sun, 22 Oct 2023 07:52:20 +0200 Subject: [PATCH] init base chain from snapshot --- base/geth-entrypoint | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/base/geth-entrypoint b/base/geth-entrypoint index cfc39e19..a0393895 100755 --- a/base/geth-entrypoint +++ b/base/geth-entrypoint @@ -26,6 +26,14 @@ else echo "$GETH_CHAINDATA_DIR exists." fi +#wget https://base-mainnet-archive-snapshots.s3.us-east-1.amazonaws.com/$(curl https://base-mainnet-archive-snapshots.s3.us-east-1.amazonaws.com/latest) + +if [ ! -f "${GETH_DATA_DIR}/bootstrapped" ]; +then + echo "downloading snapshot" + wget --tries=0 -O - "https://base-mainnet-archive-snapshots.s3.us-east-1.amazonaws.com/$(curl https://base-mainnet-archive-snapshots.s3.us-east-1.amazonaws.com/latest)" | tar -xz -C ${GETH_DHAINDATA_DIR} && touch ${GETH_DATA_DIR}/bootstrapped +fi + echo "$OP_NODE_L2_ENGINE_AUTH_RAW" > "$OP_NODE_L2_ENGINE_AUTH" if [ "${OP_GETH_ETH_STATS+x}" = x ]; then