I am planning some infrastructural architecture. It seems as if logrotate configuration files in /etc/logrotate.d
usually handle exactly one type of log rotation.
My question: Would it be possible to create a file like /etc/logrotate.d/my_company
, which configures multiple different log rotations for different log files? Is it possible to combine the content of multiple logrotate configuration files into one file?
Example:
/var/log/service_1
{
compress
delaycompress
notifempty
daily
rotate 31
}
/var/log/service_2
{
daily
rotate 7
}