Browse files

add management for providers

  • Loading branch information...
1 parent 03cf926 commit c1c21b8114b0a7895716a99ccade13b338fb3c56 Matthias Imsand committed with Marcel Haerry Nov 23, 2010
Showing with 30 additions and 1 deletion.
  1. +1 −0 files/boilerplate/providers.footer
  2. +9 −0 files/boilerplate/providers.header
  3. +2 −1 manifests/base.pp
  4. +2 −0 manifests/init.pp
  5. +16 −0 manifests/providers.pp
View
1 files/boilerplate/providers.footer
@@ -0,0 +1 @@
+#LAST LINE -- ADD YOUR ENTRIES ABOVE THIS LINE -- DO NOT REMOVE
View
9 files/boilerplate/providers.header
@@ -0,0 +1,9 @@
+#
+# Shorewall version 4 - Providers File
+#
+# For information about entries in this file, type "man shorewall-providers"
+#
+# For additional information, see http://shorewall.net/MultiISP.html
+#
+############################################################################################
+#NAME NUMBER MARK DUPLICATE INTERFACE GATEWAY OPTIONS COPY
View
3 manifests/base.pp
@@ -38,7 +38,8 @@
File["/var/lib/puppet/modules/shorewall/blacklist"],
File["/var/lib/puppet/modules/shorewall/rfc1918"],
File["/var/lib/puppet/modules/shorewall/routestopped"],
- File["/var/lib/puppet/modules/shorewall/params"]
+ File["/var/lib/puppet/modules/shorewall/params"],
+ File["/var/lib/puppet/modules/shorewall/providers"],
],
require => Package[shorewall],
}
View
2 manifests/init.pp
@@ -49,4 +49,6 @@
shorewall::managed_file { routestopped: }
# See http://www.shorewall.net/3.0/Documentation.htm#Variables
shorewall::managed_file { params: }
+ # http://www.shorewall.net/manpages/shorewall-providers.html
+ shorewall::managed_file { providers: }
}
View
16 manifests/providers.pp
@@ -0,0 +1,16 @@
+define shorewall::providers(
+ $provider,
+ $number = '',
+ $mark = '',
+ $duplicate = 'main',
+ $interface = '',
+ $gateway = '',
+ $options = '',
+ $copy = '',
+ $order='100'
+){
+ shorewall::entry{"providers.d/${order}-${name}":
+ line => "# ${name}\n${provider} ${number} ${mark} ${duplicate} ${interface} ${gateway} ${options} ${copy}"
+ }
+}
+

0 comments on commit c1c21b8

Please sign in to comment.