nixos/{pretix,pretalx}: set up log rotation (#343982)

This commit is contained in:
Martin Weinelt 2024-09-24 22:48:17 +02:00 committed by GitHub
commit aaa7fb5840
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 18 additions and 0 deletions

View File

@ -294,6 +294,15 @@ in
'')
];
services.logrotate.settings.pretalx = {
files = "${cfg.settings.filesystem.logs}/*.log";
su = "${cfg.user} ${cfg.group}";
frequency = "weekly";
rotate = "12";
copytruncate = true;
compress = true;
};
services = {
nginx = lib.mkIf cfg.nginx.enable {
enable = true;

View File

@ -403,6 +403,15 @@ in
'')
];
services.logrotate.settings.pretix = {
files = "${cfg.settings.pretix.logdir}/*.log";
su = "${cfg.user} ${cfg.group}";
frequency = "weekly";
rotate = "12";
copytruncate = true;
compress = true;
};
services = {
nginx = mkIf cfg.nginx.enable {
enable = true;