camptocamp/puppet-tomcat — pull request #69 by mremy (2014-01-27 16:40:03+00:00)
Title: Rotate catalina.out file of each instance with logrotate

On a tomcat instance, the catalina.out file is created in the shell startup file, called from the startup file (in /etc/init.d).
There is a line like this (in the script, which is at the shell level):
" >> "$CATALINA_BASE"/logs/catalina.out 2>&1 &"
This file is not manageable by the tomcat processus, and it always grows, leading to (sometime) disk full issues.

To avoid this, this patch add a basic configuration file for logrotate, with the "copytruncate" option, which may loss some lines, but I think it's a better solution than restarting the instance (unless you have memory leaks).

As the file is not managed, the user can change this configuration.
One issue can be if a logrotate configuration file to handle the catalina.out file, has already been added.