Skip to content
Snippets Groups Projects
Commit 5385f132 authored by Adam Lewenberg's avatar Adam Lewenberg
Browse files

include base::iptables to avoid error when running as puppet apply

parent ada7d007
No related branches found
No related tags found
No related merge requests found
......@@ -8,6 +8,7 @@ class base::iptables {
command => '/usr/sbin/rebuild-iptables',
refreshonly => true,
require => Package['stanford-server'],
path => '/usr/bin',
unless => '[ -e /etc/no-iptables ]',
}
......
......@@ -17,7 +17,7 @@
# Multiple ports, multiple sources, and multiple protocols can be specified.
# If only one is given, the [] brackets are optional. Description (optional)
# is used to generate a comment at the top of the file and has no other
# semantic meaning.
# semantic meaning.
#
# Protocol is required. Source and port are optional; if omitted, connections
# from any source or port are allowed. Omitting source AND port is not
......@@ -34,9 +34,12 @@ define base::iptables::rule(
if ($source == '' and $port == '') {
fail "Base::Iptables::Rule[$name] - you cannot omit both source and port"
}
include base::iptables
file { "/etc/iptables.d/${name}":
ensure => $ensure,
content => template('base/iptables/rule.erb'),
notify => Exec['rebuild-iptables'],
}
}
\ No newline at end of file
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment