#!/usr/bin/env bash # ./start-backup-restore.sh # This will: # Join riak cluster using erlcookie # via the node listening at : # and overwrite cluster data with that contained in if [ $# -lt 5 ]; then echo Usage: 1>&2 echo " `basename $0` " 1>&2 echo " " 1>&2 exit 1 fi . riak-env.sh erl -noshell -pa deps/*/ebin -pa ebin -name backup_restore -run riak_backup restore_config $1 $2 -run riak start -run riak_backup do_restore $3 $4 $2 $5 -run init stop