backup-bot-two/entrypoint.sh
Moritz d47ff6caac
Some checks failed
continuous-integration/drone/pr Build is failing
remove package versions, to avoid conflicts
2023-10-04 13:42:33 +02:00

21 lines
427 B
Bash

#!/bin/sh
set -e -o pipefail
apk add --upgrade --no-cache restic bash python3 py3-pip
# Todo use requirements file with specific versions
pip install click==8.1.7 docker==6.1.3 resticpy==1.0.2
if [ -n "$SSH_HOST_KEY" ]
then
echo "$SSH_HOST_KEY" > /root/.ssh/known_hosts
fi
cron_schedule="${CRON_SCHEDULE:?CRON_SCHEDULE not set}"
echo "$cron_schedule backup create" | crontab -
crontab -l
crond -f -d8 -L /dev/stdout