about summary refs log tree commit diff
path: root/nixos/modules/services/web-apps/pretix.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixos/modules/services/web-apps/pretix.nix')
-rw-r--r--nixos/modules/services/web-apps/pretix.nix9
1 files changed, 9 insertions, 0 deletions
diff --git a/nixos/modules/services/web-apps/pretix.nix b/nixos/modules/services/web-apps/pretix.nix
index bcd59ce40ae7..f521c49668c8 100644
--- a/nixos/modules/services/web-apps/pretix.nix
+++ b/nixos/modules/services/web-apps/pretix.nix
@@ -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;