Make backups a ton, ton more betterer
This commit is contained in:
parent
601d9543ec
commit
b793ebf587
@ -3,6 +3,9 @@ backup_script: s3backup
|
|||||||
restore_script: s3restore
|
restore_script: s3restore
|
||||||
# When to kick off backups using the systemd timer
|
# When to kick off backups using the systemd timer
|
||||||
backup_time: "*-*-* 02:00:00"
|
backup_time: "*-*-* 02:00:00"
|
||||||
|
# What variation should the systemd timer have?
|
||||||
|
# Default value of "5400" is 1h30min in seconds
|
||||||
|
backup_time_randomization: "5400"
|
||||||
# What format should the datestamps in the filenames of any backups be in?
|
# What format should the datestamps in the filenames of any backups be in?
|
||||||
# Defaults to YYYY-MM-DD-hhmm
|
# Defaults to YYYY-MM-DD-hhmm
|
||||||
# So January 5th, 2021 at 3:41PM would be 2021-01-05-1541
|
# So January 5th, 2021 at 3:41PM would be 2021-01-05-1541
|
||||||
|
@ -5,6 +5,7 @@ Description=Nightly backup timer
|
|||||||
[Timer]
|
[Timer]
|
||||||
Persistent=true
|
Persistent=true
|
||||||
OnCalendar={{ backup_time }}
|
OnCalendar={{ backup_time }}
|
||||||
|
RandomizedDelaySec={{ backup_time_randomization }}
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=timers.target
|
WantedBy=timers.target
|
||||||
|
@ -76,7 +76,6 @@ backup() {
|
|||||||
# --keep-tag foo Keeps all snapshots tagged with "foo"
|
# --keep-tag foo Keeps all snapshots tagged with "foo"
|
||||||
# --host "$HOSTNAME" Only act on *our* snapshots. We assume other machines are taking
|
# --host "$HOSTNAME" Only act on *our* snapshots. We assume other machines are taking
|
||||||
# care of their own houses.
|
# care of their own houses.
|
||||||
# --prune Remove orphaned blobs when we remove snapshots
|
|
||||||
/opt/restic-wrapper \
|
/opt/restic-wrapper \
|
||||||
--verbose \
|
--verbose \
|
||||||
forget \
|
forget \
|
||||||
@ -85,7 +84,6 @@ backup() {
|
|||||||
--keep-monthly 6 \
|
--keep-monthly 6 \
|
||||||
--keep-tag noremove \
|
--keep-tag noremove \
|
||||||
--host "$HOSTNAME" \
|
--host "$HOSTNAME" \
|
||||||
--prune
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# Dump Postgres DBs, if possible
|
# Dump Postgres DBs, if possible
|
||||||
|
Loading…
x
Reference in New Issue
Block a user