diff --git a/dist/README.md b/dist/README.md index 1eba893..555a83d 100644 --- a/dist/README.md +++ b/dist/README.md @@ -22,3 +22,7 @@ Configuration files for use with fail2ban. Assume either `backend = systemd` spe in system-wide configuration or log file written to /var/log/maddy/maddy.log. See https://github.com/foxcpp/maddy/wiki/fail2ban-configuration for details. + +## logrotate configuration + +Meant for logs rotation when logging to file is used. diff --git a/dist/logrotate.d/maddy b/dist/logrotate.d/maddy new file mode 100644 index 0000000..2c264e7 --- /dev/null +++ b/dist/logrotate.d/maddy @@ -0,0 +1,7 @@ +/var/log/maddy/maddy.log { + missingok + su maddy maddy + postrotate + /usr/bin/killall -USR1 maddy + endscript +}