renamed role

This commit is contained in:
2021-01-11 15:03:20 +01:00
parent 278d61759a
commit a213db0de3
9 changed files with 2 additions and 2 deletions

View File

@@ -0,0 +1,7 @@
[Unit]
Description=pull remote backups
OnFailure=systemd-email@%n.service
[Service]
Type=oneshot
ExecStart=/usr/bin/bash /usr/local/bin/pull-remote-backups.sh

View File

@@ -0,0 +1,8 @@
#!/bin/bash
# Pulls the remote backups from multiple hosts
hosts="{{pull_remote_backups_hosts}}";
errors=0
for host in $hosts; do
bash /usr/local/bin/pull-remote-backup.sh $host || ((errors+=1));
done;
exit $errors;

View File

@@ -0,0 +1,9 @@
[Unit]
Description=starts pull remote backup timer
[Timer]
OnCalendar=22:00
RandomizedDelaySec=1h
[Install]
WantedBy=timers.target