From 48fad255975ccbe9b58bb1e17882a4357f8721ab Mon Sep 17 00:00:00 2001 From: mh Date: Thu, 24 Aug 2017 19:15:12 +0200 Subject: workaround a bug in facter that sets ipaddress6 to ipv4 addresses --- manifests/init.pp | 10 ++++++++++ 1 file changed, 10 insertions(+) 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, -- cgit v1.2.3