diff --git a/manifests/config.pp b/manifests/config.pp index c74f5119..c3c248cf 100644 --- a/manifests/config.pp +++ b/manifests/config.pp @@ -26,4 +26,4 @@ create_resources('logrotate::conf', $custom_config) } -} \ No newline at end of file +} diff --git a/manifests/defaults.pp b/manifests/defaults.pp index ed623225..f4127f36 100644 --- a/manifests/defaults.pp +++ b/manifests/defaults.pp @@ -28,18 +28,15 @@ } if !defined( Logrotate::Rule['wtmp'] ) { - logrotate::rule { - 'wtmp': + logrotate::rule { 'wtmp': path => '/var/log/wtmp', create_mode => '0664', } } if !defined( Logrotate::Rule['btmp'] ) { - logrotate::rule { - 'btmp': + logrotate::rule { 'btmp': path => '/var/log/btmp', create_mode => '0600', - } } } @@ -93,8 +90,7 @@ } if !defined( Logrotate::Rule['wtmp'] ) { - logrotate::rule { - 'wtmp': + logrotate::rule { 'wtmp': path => '/var/log/wtmp', create_mode => '0664', missingok => false, @@ -102,11 +98,10 @@ } } if !defined( Logrotate::Rule['btmp'] ) { - logrotate::rule { - 'btmp': + logrotate::rule { 'btmp': path => '/var/log/btmp', create_mode => '0600', - minsize => '1M'; + minsize => '1M', } } } @@ -127,17 +122,15 @@ } if !defined( Logrotate::Rule['wtmp'] ) { - logrotate::rule { - 'wtmp': + logrotate::rule { 'wtmp': path => '/var/log/wtmp', create_mode => '0664', - missingok => false; + missingok => false, } } if !defined( Logrotate::Rule['btmp'] ) { - logrotate::rule { - 'btmp': + logrotate::rule { 'btmp': path => '/var/log/btmp', create_mode => '0600', create_group => 'root', @@ -150,4 +143,4 @@ } } } -} \ No newline at end of file +} diff --git a/manifests/hourly.pp b/manifests/hourly.pp index 1dc2b766..fc5c2e53 100644 --- a/manifests/hourly.pp +++ b/manifests/hourly.pp @@ -25,21 +25,18 @@ } } - file { - '/etc/logrotate.d/hourly': + file { '/etc/logrotate.d/hourly': ensure => $dir_ensure, owner => 'root', group => 'root', - mode => '0755'; - '/etc/cron.hourly/logrotate': + mode => '0755', + } + file { '/etc/cron.hourly/logrotate': ensure => $ensure, owner => 'root', group => 'root', mode => '0555', source => 'puppet:///modules/logrotate/etc/cron.hourly/logrotate', - require => [ - File['/etc/logrotate.d/hourly'], - Package['logrotate'], - ]; + require => [ File['/etc/logrotate.d/hourly'], Package['logrotate'], ], } }