Skip to content

Commit

Permalink
Merge pull request #102 from dappnode/fix/101_update_snapshot_url
Browse files Browse the repository at this point in the history
  • Loading branch information
mgarciate authored Aug 18, 2023
2 parents 32cb0f3 + 2f4dfd2 commit bedb5d0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions alephium/snapshot-loader.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ then
echo "Loading $ALEPHIUM_NETWORK snapshot from official https://archives.alephium.org"
# Creating a temp folder (on the same volume) where snapshot will be loaded
mkdir "$ALEPHIUM_HOME/${ALEPHIUM_NETWORK}-snapshot"
curl -L "$(curl -s https://s3.eu-central-1.amazonaws.com/archives.alephium.org/archives/$ALEPHIUM_NETWORK/full-node-data/_latest.txt)" | $TEE_HASH_CMD | tar xf - -C "$ALEPHIUM_HOME/${ALEPHIUM_NETWORK}-snapshot"
curl -L "$(curl -s https://archives.alephium.org/archives/$ALEPHIUM_NETWORK/full-node-data/_latest.txt)" | $TEE_HASH_CMD | tar xf - -C "$ALEPHIUM_HOME/${ALEPHIUM_NETWORK}-snapshot"
res=$?
if [ "$res" != "0" ]; # If curl or tar command failed, stopping the load of the snapshot.
then
Expand All @@ -54,7 +54,7 @@ then
if [ "${VALIDATE_CHECKSUM}" = "1" ]
then
# Check sha256 of what has been downloaded
remote_sha256sum="$(curl -s https://s3.eu-central-1.amazonaws.com/archives.alephium.org/archives/$ALEPHIUM_NETWORK/full-node-data/_latest.txt.sha256sum)"
remote_sha256sum="$(curl -s https://archives.alephium.org/archives/$ALEPHIUM_NETWORK/full-node-data/_latest.txt.sha256sum)"
local_sha256sum=$(cat "${CHECKSUM_FILE}")
if [ "$remote_sha256sum" != "$local_sha256sum" ]
then
Expand Down

0 comments on commit bedb5d0

Please sign in to comment.