Add weekly logrotation of FTL's log (#1509)

pull/1513/head
DL6ER 7 years ago committed by GitHub
parent 01e091fd17
commit 8ef64dbe74

@ -8,3 +8,14 @@
notifempty
nomail
}
/var/log/pihole-FTL.log {
# su #
weekly
copytruncate
rotate 3
compress
delaycompress
notifempty
nomail
}

@ -1080,7 +1080,7 @@ installLogrotate() {
# the local properties of the /var/log directory
logusergroup="$(stat -c '%U %G' /var/log)"
if [[ ! -z $logusergroup ]]; then
sed -i "s/# su #/su ${logusergroup}/" /etc/pihole/logrotate
sed -i "s/# su #/su ${logusergroup}/g;" /etc/pihole/logrotate
fi
echo " done!"
}

Loading…
Cancel
Save