Browse Source

Merge pull request #75 from matrix-org/dbkr/keep_more_logs

Keep a year(ish) worth of logs
David Baker 5 years ago
parent
commit
f76f5c92a1
1 changed files with 2 additions and 2 deletions
  1. 2 2
      sydent/sydent.py

+ 2 - 2
sydent/sydent.py

@@ -97,8 +97,8 @@ class Sydent:
 
         logPath = self.cfg.get('general', "log.path")
         if logPath != '':
-            handler = logging.handlers.RotatingFileHandler(
-                logPath, maxBytes=(1000 * 1000 * 100), backupCount=3
+            handler = logging.handlers.TimedRotatingFileHandler(
+                logPath, when='midnight', backupCount=365
             )
             handler.setFormatter(formatter)
             def sighup(signum, stack):