#!/bin/bash if [ -z "$1" ]; then echo "$(basename $0) zip-file-to-restore.zip" exit 1 fi file=$(pwd)/$1 cd $HOME/workdir/app unzip "$file" source ../environment mongorestore --drop --uri $FRETLINK_MONGO_URI $(pwd)/.dump/ if [ -e "../fixtures" ]; then source ../fixtures fi