mirror of
https://github.com/offen/docker-volume-backup.git
synced 2024-11-10 08:55:45 +08:00
14 lines
346 B
Bash
14 lines
346 B
Bash
#!/bin/sh
|
|
|
|
# Copyright 2021 - Offen Authors <hioffen@posteo.de>
|
|
# SPDX-License-Identifier: MPL-2.0
|
|
|
|
set -e
|
|
|
|
BACKUP_CRON_EXPRESSION="${BACKUP_CRON_EXPRESSION:-@daily}"
|
|
|
|
echo "Installing cron.d entry with expression $BACKUP_CRON_EXPRESSION."
|
|
echo "$BACKUP_CRON_EXPRESSION backup 2>&1" | crontab -
|
|
|
|
echo "Starting cron in foreground."
|
|
crond -f -l 8
|