backup-docker/entrypoint.sh
Djeeberjr 5f8248d236
All checks were successful
continuous-integration/drone/push Build is passing
added entrypoint
2022-03-27 01:31:46 +01:00

43 lines
589 B
Bash
Executable File

#!/usr/bin/env sh
set -e
COMMAND="$1"
# print usage if no command is given
if [ -z "$COMMAND" ]; then
echo "Usage: $0 <command>"
echo "Available commands:"
echo " backup"
echo " restore"
echo " init TODO"
echo " interactive"
exit 1
fi
. /app/setup.sh
case "$COMMAND" in
backup)
# backup
/app/backup.sh
;;
restore)
# restore
/app/restore.sh
;;
init)
# init
# TODO: implement
/app/init.sh
;;
interactive)
# interactive
/app/interactive.sh
;;
*)
echo "Unknown command: $COMMAND"
exit 1
;;
esac