3 # This class installs ferm and sets up rules
10 # realize (i.e. enable) all @ferm::rule virtual resources
14 File { mode => '0400' }
19 if ($::lsbmajdistrelease >= 8) {
24 # Remove instead of purge ulogd because it deletes log files on purge.
35 status => '/bin/true',
38 $munin_ips = split(regsubst($::v4ips, '([^,]+)', 'ip_\1', 'G'), ',')
40 munin::check { $munin_ips: script => 'ip_', }
43 $munin6_ips = split(regsubst($::v6ips, '([^,]+)', 'ip_\1', 'G'), ',')
44 munin::ipv6check { $munin6_ips: }
47 # get rid of old stuff
48 $munin6_ip6s = split(regsubst($::v6ips, '([^,]+)', 'ip6_\1', 'G'), ',')
49 munin::check { $munin6_ip6s: ensure => absent }
53 notify => Service['ferm'],
54 require => Package['ferm'],
57 file { '/etc/ferm/dsa.d':
63 source => 'puppet:///files/empty/',
65 file { '/etc/ferm/conf.d':
71 source => 'puppet:///files/empty/',
73 file { '/etc/default/ferm':
74 source => 'puppet:///modules/ferm/ferm.default',
75 require => Package['ferm'],
76 notify => Service['ferm'],
79 file { '/etc/ferm/ferm.conf':
80 content => template('ferm/ferm.conf.erb'),
81 notify => Service['ferm'],
83 file { '/etc/ferm/conf.d/me.conf':
84 content => template('ferm/me.conf.erb'),
85 notify => Service['ferm'],
87 file { '/etc/ferm/conf.d/defs.conf':
88 content => template('ferm/defs.conf.erb'),
89 notify => Service['ferm'],
91 file { '/etc/ferm/conf.d/interfaces.conf':
92 content => template('ferm/interfaces.conf.erb'),
93 notify => Service['ferm'],
95 if ($::lsbmajdistrelease >= 8) {
96 augeas { 'logrotate_ulogd2':
97 context => '/files/etc/logrotate.d/ulogd2',
99 'set rule/schedule daily',
100 'set rule/delaycompress delaycompress',
101 'set rule/rotate 10',
102 'set rule/ifempty notifempty',
105 file { '/etc/logrotate.d/ulogd':
108 file { '/etc/logrotate.d/ulogd.dpkg-bak':
111 file { '/etc/logrotate.d/ulogd.dpkg-dist':
115 file { '/etc/logrotate.d/ulogd':
116 source => 'puppet:///modules/ferm/logrotate-ulogd',
118 require => Package['debian.org'],