Skip to content

Commit

Permalink
Merge pull request #1998 from matter-labs/slumber-data-restore-docker…
Browse files Browse the repository at this point in the history
…-finite-mode

data-restore: allow running in non-finite mode in docker
  • Loading branch information
Deniallugo authored Nov 10, 2021
2 parents 9561054 + 7c7a5ea commit 6f510db
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion docker/data-restore/data-restore-entry.sh
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,20 @@ case $NETWORK in
;;
esac

# Default to executing data restore in a finite mode.
MODE="--finite"
case $FINITE_MODE in
"true" | "")
;;
"false")
MODE=""
;;
*)
echo "Invalid value of FINITE_MODE: expected boolean"
exit 1
;;
esac

if [[ -n $PG_DUMP && "$COMMAND" == "--continue" ]]
then
# Do not drop db if the file doesn't exist.
Expand All @@ -56,4 +70,4 @@ fi

CONFIG_FILE="/usr/src/configs/${NETWORK}.json"

zk f ./target/release/zksync_data_restore $COMMAND --finite --config $CONFIG_FILE --web3 $WEB3_URL || exit 1
zk f ./target/release/zksync_data_restore $COMMAND $MODE --config $CONFIG_FILE --web3 $WEB3_URL || exit 1

0 comments on commit 6f510db

Please sign in to comment.