summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormh <mh@immerda.ch>2017-08-24 19:15:12 +0200
committermh <mh@immerda.ch>2017-08-24 19:15:12 +0200
commit48fad255975ccbe9b58bb1e17882a4357f8721ab (patch)
treec8ee3229dcd8c6b6715ecd83a3673827f6ae2e5b
parent4b9c6e1714857a702add52b1176eb65d347ac71d (diff)
workaround a bug in facter that sets ipaddress6 to ipv4 addresses
-rw-r--r--manifests/init.pp10
1 files changed, 10 insertions, 0 deletions
diff --git a/manifests/init.pp b/manifests/init.pp
index 93f71f7..7f9676d 100644
--- a/manifests/init.pp
+++ b/manifests/init.pp
@@ -68,6 +68,16 @@ class shorewall(
$merged_settings = merge($def_settings,$settings)
+ # workaround https://tickets.puppetlabs.com/browse/FACT-1739
+ if $shorewall6 == 'auto' {
+ if $ipaddress6 and $ipaddress6 =~ /:/ {
+ $with_shorewall6 = true
+ } else {
+ $with_shorewall6 = false
+ }
+ } else {
+ $with_shorewall6 = str2bool($shorewall6)
+ }
$with_shorewall6 = $shorewall6 ? {
'auto' => $ipaddress6 ? {
undef => false,