From 082577f27b1bd04cda2a958bfcf1c205188aa56d Mon Sep 17 00:00:00 2001 From: Dominik Winter Date: Fri, 11 Mar 2016 21:37:04 +0100 Subject: [PATCH] continue to write the log information in the newly created file after rotating the old log file --- start-mailserver.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/start-mailserver.sh b/start-mailserver.sh index e8668a36..e24d6f8f 100644 --- a/start-mailserver.sh +++ b/start-mailserver.sh @@ -158,7 +158,7 @@ case $DMS_SSL in sed -i -r 's/TLS_CERTFILE=\/etc\/courier\/pop3d.pem/TLS_CERTFILE=\/etc\/postfix\/ssl\/'$(hostname)'-full.pem/g' /etc/courier/pop3d-ssl echo "SSL configured with CA signed/custom certificates" - + fi ;; @@ -224,6 +224,8 @@ sed -i "/^findtime *=/c\findtime = 10800" /etc/fail2ban/jail.conf # avoid warning on startup echo "ignoreregex =" >> /etc/fail2ban/filter.d/postfix-sasl.conf +# continue to write the log information in the newly created file after rotating the old log file +sed -i -r "/^#?compress/c\compress\ncopytruncate" /etc/logrotate.conf echo "Starting daemons" cron