From aee37040009edb28105f06ebc615f4b55d5d56a9 Mon Sep 17 00:00:00 2001 From: mh Date: Thu, 24 Aug 2017 21:14:20 +0200 Subject: make sure we also en/disable it based on the right setting --- manifests/init.pp | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/manifests/init.pp b/manifests/init.pp index cf7d5b8..61187f0 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -57,17 +57,6 @@ class shorewall( $daily_check = true, ) { - $disable_ipv6 = $ipaddress6 ? { - undef => 'Yes', - default => 'No', - } - $def_settings = { - 'LOG_MARTIANS' => 'No', - 'DISABLE_IPV6' => $disable_ipv6, - } - - $merged_settings = merge($def_settings,$settings) - # workaround https://tickets.puppetlabs.com/browse/FACT-1739 if $shorewall6 == 'auto' { if $ipaddress6 and $ipaddress6 =~ /:/ { @@ -79,6 +68,17 @@ class shorewall( $with_shorewall6 = str2bool($shorewall6) } + $disable_ipv6 = $with_shorewall6 ? { + false => 'Yes', + default => 'No', + } + $def_settings = { + 'LOG_MARTIANS' => 'No', + 'DISABLE_IPV6' => $disable_ipv6, + } + + $merged_settings = merge($def_settings,$settings) + case $::operatingsystem { 'Gentoo': { include ::shorewall::gentoo } 'Debian','Ubuntu': { include ::shorewall::debian } -- cgit v1.2.3