Skip to content

Customize Rails' Log Rotation

technicalpickles edited this page Nov 21, 2012 · 2 revisions

Moonshine provides logrotate for your application's log directory automatically. Sometimes you may need to keep them longer, for whatever reason.

Most common is to change the options. Here's an example you can add to your config/moonshine.yml:

:rails_logrotate:
  :options:
    - daily
    - missingok
    - compress
    - delaycompress
    - sharedscripts

These are actually the defaults. Check out the man page for all the logrotate options.

Clone this wiki locally