Add a weekly dump of the Garmin database

garmin-dump.timer runs garmin-dump weekly, keeping the two newest ISO weeks in
~/.local/share/negsplit/dumps, which simple_backup then copies; the login comes
from ~/.config/negsplit/dump.cnf (not tracked).
This commit is contained in:
Daniele Fucini
2026-10-31 11:30:03 +01:00
parent cc8eaebd5f
commit 831238e040
4 changed files with 45 additions and 1 deletions
+11
View File
@@ -0,0 +1,11 @@
[Unit]
Description=Dump the Garmin database to ~/.local/share/negsplit/dumps
StartLimitIntervalSec=2h
StartLimitBurst=4
[Service]
Type=oneshot
ExecStart=%h/.local/bin/garmin-dump
# MariaDB not up yet (e.g. caught up right after boot)? retry a few times
Restart=on-failure
RestartSec=5min
+9
View File
@@ -0,0 +1,9 @@
[Unit]
Description=Dump the Garmin database weekly
[Timer]
OnCalendar=weekly
Persistent=true
[Install]
WantedBy=timers.target