Converted tabs to spaces from firewall and mythtv modules.
This commit is contained in:
parent
335b2e7735
commit
31b1277c8e
2 changed files with 84 additions and 84 deletions
|
@ -27,15 +27,15 @@ class firewall {
|
|||
}
|
||||
|
||||
case $operatingsystem {
|
||||
centos,debian,fedora,ubuntu: {
|
||||
include firewall::iptables
|
||||
}
|
||||
openbsd: {
|
||||
include firewall::pf
|
||||
}
|
||||
default: {
|
||||
fail("Firewall module not supported in ${operatingsystem}")
|
||||
}
|
||||
centos,debian,fedora,ubuntu: {
|
||||
include firewall::iptables
|
||||
}
|
||||
openbsd: {
|
||||
include firewall::pf
|
||||
}
|
||||
default: {
|
||||
fail("Firewall module not supported in ${operatingsystem}")
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -54,15 +54,15 @@ class firewall {
|
|||
class firewall::custom {
|
||||
|
||||
case $operatingsystem {
|
||||
centos,debian,fedora,ubuntu: {
|
||||
include firewall::custom::iptables
|
||||
}
|
||||
openbsd: {
|
||||
include firewall::custom::pf
|
||||
}
|
||||
default: {
|
||||
fail("Firewall module not supported in ${operatingsystem}")
|
||||
}
|
||||
centos,debian,fedora,ubuntu: {
|
||||
include firewall::custom::iptables
|
||||
}
|
||||
openbsd: {
|
||||
include firewall::custom::pf
|
||||
}
|
||||
default: {
|
||||
fail("Firewall module not supported in ${operatingsystem}")
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -87,12 +87,12 @@ class firewall::common::iptables {
|
|||
ubuntu => "/etc/iptables/rules",
|
||||
default => "/etc/sysconfig/iptables",
|
||||
},
|
||||
ensure => present,
|
||||
mode => 0600,
|
||||
owner => root,
|
||||
group => root,
|
||||
require => Package["iptables"],
|
||||
notify => Service["iptables"],
|
||||
ensure => present,
|
||||
mode => 0600,
|
||||
owner => root,
|
||||
group => root,
|
||||
require => Package["iptables"],
|
||||
notify => Service["iptables"],
|
||||
}
|
||||
|
||||
case $operatingsystem {
|
||||
|
@ -122,16 +122,16 @@ class firewall::common::iptables {
|
|||
ubuntu => "iptables-persistent",
|
||||
default => "iptables",
|
||||
},
|
||||
ensure => running,
|
||||
enable => true,
|
||||
hasrestart => $operatingsystem ? {
|
||||
ensure => running,
|
||||
enable => true,
|
||||
hasrestart => $operatingsystem ? {
|
||||
centos => true,
|
||||
debian => false,
|
||||
fedora => true,
|
||||
ubuntu => false,
|
||||
},
|
||||
status => "iptables -t filter --list --line-numbers | egrep '^1'",
|
||||
require => Package["iptables"],
|
||||
require => Package["iptables"],
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -142,7 +142,7 @@ class firewall::common::iptables {
|
|||
class firewall::iptables inherits firewall::common::iptables {
|
||||
|
||||
File["/etc/sysconfig/iptables"] {
|
||||
content => template("firewall/iptables.erb"),
|
||||
content => template("firewall/iptables.erb"),
|
||||
}
|
||||
|
||||
case $operatingsystem {
|
||||
|
@ -161,8 +161,8 @@ class firewall::iptables inherits firewall::common::iptables {
|
|||
class firewall::custom::iptables inherits firewall::common::iptables {
|
||||
|
||||
File["/etc/sysconfig/iptables"] {
|
||||
source => [ "puppet:///files/firewall/iptables.${fqdn}",
|
||||
"puppet:///files/firewall/iptables", ],
|
||||
source => [ "puppet:///files/firewall/iptables.${fqdn}",
|
||||
"puppet:///files/firewall/iptables", ],
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -173,16 +173,16 @@ class firewall::custom::iptables inherits firewall::common::iptables {
|
|||
class firewall::common::pf {
|
||||
|
||||
file { "/etc/pf.conf":
|
||||
ensure => present,
|
||||
mode => 0600,
|
||||
owner => root,
|
||||
group => wheel,
|
||||
notify => Exec["pfctl -f /etc/pf.conf"],
|
||||
ensure => present,
|
||||
mode => 0600,
|
||||
owner => root,
|
||||
group => wheel,
|
||||
notify => Exec["pfctl -f /etc/pf.conf"],
|
||||
}
|
||||
|
||||
exec { "pfctl -f /etc/pf.conf":
|
||||
path => "/bin:/usr/bin:/sbin:/usr/sbin",
|
||||
refreshonly => true,
|
||||
path => "/bin:/usr/bin:/sbin:/usr/sbin",
|
||||
refreshonly => true,
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -193,7 +193,7 @@ class firewall::common::pf {
|
|||
class firewall::pf inherits firewall::common::pf {
|
||||
|
||||
File["/etc/pf.conf"] {
|
||||
content => template("firewall/pf.conf.erb"),
|
||||
content => template("firewall/pf.conf.erb"),
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -204,8 +204,8 @@ class firewall::pf inherits firewall::common::pf {
|
|||
class firewall::custom::pf inherits firewall::common::pf {
|
||||
|
||||
File["/etc/pf.conf"] {
|
||||
source => [ "puppet:///files/firewall/pf.conf.${fqdn}",
|
||||
"puppet:///files/firewall/pf.conf", ],
|
||||
source => [ "puppet:///files/firewall/pf.conf.${fqdn}",
|
||||
"puppet:///files/firewall/pf.conf", ],
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue