mirror of
https://github.com/chylex/My-Server-Docker-Setup.git
synced 2025-03-14 13:15:49 +01:00
13 lines
348 B
Bash
13 lines
348 B
Bash
#!/bin/bash
|
|
set -e
|
|
|
|
if [ -f "/backup/restore" ]; then
|
|
echo "A backup restore file is present, it is not safe to resume the backup schedule. Waiting for the file to be removed..."
|
|
while [ -f "/backup/restore" ]; do
|
|
sleep 5s
|
|
done
|
|
fi
|
|
|
|
echo "${CRON:-"0 */2 * * *"} /bin/bash /scripts/backup.sh" > /crontab
|
|
/bin/supercronic /crontab
|