Make services persistent

#1

Most services have a startAt option e.g.
services.borgbackup.jobs.<name>.startAt and systemd.services.<name>startAt
which is very convenient such as is automatically creates a timer. However this timer does not seem to be persistent which triggers the service immediately if it missed the last start time.

Is there a way to make these services persistent without creating a extra systemd.timer?
If no, how do I create a systemd.timer with - in the name? The borg services are called borgbackup-job-name.

1 Like

#2

Hi

I had the exact same problem.

Just adding this to your NixOS configuration will fix your problem (replace <name> the job name):

    systemd.timers."borgbackup-job-<name>".timerConfig.Persistent = true;
4 Likes