3657cacfca
Add a logrotate role that allows basic configuration of a logrotate configuration for a specific log-file. Use this role in the ansible-cron and install-ansible roles to ensure the log output they are generating is rotated. This role is not intended to manage the logrotate package (mostly to avoid the overhead of frequently checking package state when this is expected to be called for multiple configuration files on a server). We add it as a base package to our servers. Tests are added for testinfra. Change-Id: I90f59c3e42c1135d6be120de38e942ece608b761 |
||
---|---|---|
.. | ||
defaults | ||
tasks | ||
templates | ||
README.rst |
Add log rotation file
Note
This role does not manage the logrotate
package or
configuration directory, and it is assumed to be installed and
available.
This role installs a log rotation file in
/etc/logrotate.d/
for a given file.
For information on the directives see logrotate.conf(5)
.
This is not an exhaustive list of directives (contributions are
welcome).
** Role Variables **
The log file on disk to rotate