mirror of
https://github.com/nix-community/home-manager
synced 2024-11-05 02:39:45 +01:00
ca69be9335
This reflects a systemd service sample file change made in borgmatic 1.7.6, commit 2e9f70d49647d47fb4ca05f428c592b0e4319544: When backing up a machine with a monitor using logind to control idle timeout and things like DPMS, borgmatic can block the screen from turning on/off with systemd-inhibit. This is because by default systemd-inhibit will block "idle:sleep:shutdown". Borgmatic does not need to care about idle, only about suspend and shutdown. So, add an explicit `--what` flag for what borgmatic should inhibit. For more information see systemd-inhibit(1).
24 lines
587 B
Desktop File
24 lines
587 B
Desktop File
[Service]
|
|
CPUSchedulingPolicy=batch
|
|
ExecStart=/nix/store/00000000000000000000000000000000-systemd/bin/systemd-inhibit \
|
|
--who="borgmatic" \
|
|
--what="sleep:shutdown" \
|
|
--why="Prevent interrupting scheduled backup" \
|
|
@borgmatic@/bin/borgmatic \
|
|
--stats \
|
|
--verbosity -1 \
|
|
--list \
|
|
--syslog-verbosity 1
|
|
|
|
ExecStartPre=/nix/store/00000000000000000000000000000000-coreutils/bin/sleep 3m
|
|
IOSchedulingClass=best-effort
|
|
IOSchedulingPriority=7
|
|
IOWeight=100
|
|
LogRateLimitIntervalSec=0
|
|
Nice=19
|
|
Restart=no
|
|
Type=oneshot
|
|
|
|
[Unit]
|
|
ConditionACPower=true
|
|
Description=borgmatic backup
|