blob: b8768b04433cf88bdce0d01476335b471bf34d12 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
# a core wrapper for all kinds of entries
define shorewall::entry(
$line,
$ensure = present,
$shorewall = true,
$shorewall6 = false,
){
if $ensure == 'present' {
$parts = split($name,'-')
if $shorewall {
concat::fragment{$name:
ensure => $ensure,
content => "${line}\n",
order => $parts[1],
target => "/etc/shorewall/puppet/${parts[0]}",
}
}
if $shorewall6 and $shorewall::with_shorewall6 {
concat::fragment{"shorewall6_${name}":
ensure => $ensure,
content => "${line}\n",
order => $parts[1],
target => "/etc/shorewall6/puppet/${parts[0]}",
}
}
}
}
|