services/logrotate: init for custom state path

This commit is contained in:
Lu Wang 2024-12-26 23:51:37 +08:00
parent fa9a4b9ae0
commit 6c422a41c6
Signed by: rebmit
SSH key fingerprint: SHA256:3px8QV1zEerIrEWHaqtH5rR9kjetyRST5EipOPrd+bU
2 changed files with 15 additions and 0 deletions

View file

@ -21,6 +21,7 @@ let
services.btrfs-auto-scrub services.btrfs-auto-scrub
services.dbus services.dbus
services.journald services.journald
services.logrotate
services.nscd services.nscd
services.openssh services.openssh
services.zram-generator services.zram-generator

View file

@ -0,0 +1,14 @@
{ ... }:
{
services.logrotate = {
enable = true;
extraArgs = [
"-s"
"/var/lib/logrotate/status"
];
};
systemd.services.logrotate.serviceConfig = {
StateDirectory = "logrotate";
};
}