Skip to content

Instantly share code, notes, and snippets.

@s0what
Created March 6, 2012 11:55
Show Gist options
  • Save s0what/1985858 to your computer and use it in GitHub Desktop.
Save s0what/1985858 to your computer and use it in GitHub Desktop.
logrotate for nginx
/var/log/nginx/*.log{
daily
missingok
rotate 7
compress
dateext
delaycompress
notifempty
sharedscripts
postrotate
test ! -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