Skip to content

Commit f9a84ab

Browse files
committed
restore snapshot from local only
1 parent 5c57f8f commit f9a84ab

File tree

1 file changed

+3
-8
lines changed

1 file changed

+3
-8
lines changed

snapshot/snapshot_download.sh

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -75,16 +75,11 @@ rm -rf $node_home/data/*
7575

7676
cd $node_home
7777

78-
# always try from our local snapshot first, if failure => use external providers
78+
7979
BASE_URL="http://localhost/"
8080
URL="http://localhost/chain.json"
81-
status_code=$(curl -s -o /dev/null -w "%{http_code}" --connect-timeout 3 --max-time 3 $URL)
82-
if [[ $status_code == "200" ]]; then
83-
URL=`curl -s $URL |jq -r '.snapshot_url'`
84-
URL="${BASE_URL}${URL##*/}"
85-
fi
86-
87-
81+
URL=`curl -s $URL |jq -r '.snapshot_url'`
82+
URL="${BASE_URL}${URL##*/}"
8883
echo "URL=$URL"
8984

9085
if [[ -z $URL ]]; then

0 commit comments

Comments
 (0)