Skip to content

Instantly share code, notes, and snippets.

@westphahl
Created April 8, 2010 19:35
Show Gist options
  • Save westphahl/360442 to your computer and use it in GitHub Desktop.
Save westphahl/360442 to your computer and use it in GitHub Desktop.
logrotate.d script for Nginx
/var/log/nginx/*.log {
daily
missingok
rotate 52
compress
delaycompress
notifempty
create 640 root adm
sharedscripts
postrotate
[ ! -f /var/run/nginx.pid ] || kill -USR1 `cat /var/run/nginx.pid`
endscript
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment