mirror of
https://github.com/mail-in-a-box/mailinabox.git
synced 2024-11-23 02:27:05 +00:00
Merge pull request #598 from yodax/zpush-log-rotate
Add log rotation to z-push
This commit is contained in:
commit
34ba279b0a
@ -75,6 +75,19 @@ chmod 750 /var/lib/z-push
|
|||||||
chown www-data:www-data /var/log/z-push
|
chown www-data:www-data /var/log/z-push
|
||||||
chown www-data:www-data /var/lib/z-push
|
chown www-data:www-data /var/lib/z-push
|
||||||
|
|
||||||
|
# Add log rotation
|
||||||
|
|
||||||
|
cat > /etc/logrotate.d/z-push <<EOF;
|
||||||
|
/var/log/z-push/*.log {
|
||||||
|
weekly
|
||||||
|
missingok
|
||||||
|
rotate 52
|
||||||
|
compress
|
||||||
|
delaycompress
|
||||||
|
notifempty
|
||||||
|
}
|
||||||
|
EOF
|
||||||
|
|
||||||
# Restart service.
|
# Restart service.
|
||||||
|
|
||||||
restart_service php5-fpm
|
restart_service php5-fpm
|
||||||
|
Loading…
Reference in New Issue
Block a user