countme: Persist last timer trigger to handle system suspends

Set `Persistent=yes` in the timer unit to make sure that systems that
are not running 24/7 gets counted when they wake up if they missed the
previous timer run / counting window.

This is mostly for Fedora Silverblue and IoT like systems as Fedora
CoreOS systems usually run 24/7.

https://www.freedesktop.org/software/systemd/man/systemd.timer.html#Persistent=
This commit is contained in:
Timothée Ravier 2021-02-16 11:41:26 +01:00 committed by OpenShift Merge Robot
parent 0c9f7ab7eb
commit 790e709360

View File

@ -8,6 +8,7 @@ ConditionPathExists=/run/ostree-booted
OnCalendar=weekly UTC
AccuracySec=1u
RandomizedDelaySec=1w
Persistent=yes
[Install]
WantedBy=timers.target