Skip to content

Instantly share code, notes, and snippets.

@CodeOfficer
Forked from henrik/logrotate.conf
Created February 24, 2009 01:11
Show Gist options
  • Save CodeOfficer/69311 to your computer and use it in GitHub Desktop.
Save CodeOfficer/69311 to your computer and use it in GitHub Desktop.
# Install logrotate on OS X:
# sudo port clean --all logrotate && sudo port install logrotate
# Add e.g. this to your crontab:
# /opt/local/sbin/logrotate -s /Users/deploy/.logrotate/sites.status /Users/deploy/.logrotate/sites.conf
# This file would be sites.conf.
# See http://overstimulate.com/articles/logrotate-rails-passenger for more info.
daily
missingok
rotate 30
compress
delaycompress
sharedscripts
/Users/deploy/Sites/rails.example.com/shared/log/*.log {
postrotate
touch /Users/deploy/Sites/rails.example.com/current/tmp/restart.txt
endscript
}
/Users/deploy/Sites/merb.example.com/shared/log/*.log {
postrotate
touch /Users/deploy/Sites/merb.example.com/current/tmp/restart.txt
endscript
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment