1
Fork 0
mirror of https://github.com/Steffo99/backup-duplicity.git synced 2024-12-22 11:34:22 +00:00
gestalt-amadeus/entrypoint.sh

20 lines
350 B
Bash
Raw Normal View History

2023-05-17 12:27:55 +00:00
#!/bin/sh
2023-05-17 12:36:47 +00:00
case "$MODE" in
backup)
2024-10-24 08:38:59 +00:00
echo "Running first backup..."
/etc/periodic/daily/backup.sh
echo "Running cron for daily backups..."
crond -f -l 0
echo "Cron has exited."
2023-05-17 12:36:47 +00:00
;;
restore)
2024-10-24 08:38:59 +00:00
echo "Restoring from latest backup..."
/usr/lib/backup-duplicity/restore.sh
echo "Done."
2023-05-17 12:36:47 +00:00
;;
*)
echo "No such mode." >> /dev/stderr
;;
esac