diff --git a/bind/config.sls b/bind/config.sls index b6fd090..c0ff2a4 100644 --- a/bind/config.sls +++ b/bind/config.sls @@ -106,6 +106,16 @@ bind_default_zones: - user: root - group: bind - mode: 775 + - template: jinja + + +/etc/logrotate.d/bind9: + file: + - managed + - source: salt://bind/files/debian/logrotate_bind + - user: root + - group: root + {% endif %} {% for key,args in salt['pillar.get']('bind:configured_zones', {}).iteritems() -%} diff --git a/bind/files/debian/logrotate_bind b/bind/files/debian/logrotate_bind new file mode 100644 index 0000000..09eab0b --- /dev/null +++ b/bind/files/debian/logrotate_bind @@ -0,0 +1,10 @@ +/var/log/bind9/query.log { + rotate 7 + daily + missingok + notifempty + sharedscripts + copytruncate + compress + create 0664 bind root +}