From: Morten Brekkevold <morten.brekkevold@uninett.no> Date: Wed, 17 Feb 2016 11:59:47 +0000 (+0100) Subject: Add pim protocol to puppetlabs-firewall X-Git-Tag: 1.8.2~47^2~1 X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=69f547f341ff0e1648f9f4a3e1713878a4def497;p=puppet-modules%2Fpuppetlabs-firewall.git Add pim protocol to puppetlabs-firewall --- diff --git a/README.markdown b/README.markdown index 0b74b81..26467e0 100644 --- a/README.markdown +++ b/README.markdown @@ -641,6 +641,7 @@ firewall { '999 this runs last': * 'ipencap' * 'ospf' * 'gre' + * 'pim' * 'all' * `provider`: The specific backend to use for this firewall resource. You will seldom need to specify this --- Puppet will usually discover the appropriate provider for your platform. Available providers are ip6tables and iptables. See the [Providers](#providers) section above for details about these providers. diff --git a/lib/puppet/type/firewall.rb b/lib/puppet/type/firewall.rb index e68b2d6..4073d6c 100644 --- a/lib/puppet/type/firewall.rb +++ b/lib/puppet/type/firewall.rb @@ -369,7 +369,7 @@ Puppet::Type.newtype(:firewall) do *tcp*. EOS - newvalues(*[:tcp, :udp, :icmp, :"ipv6-icmp", :esp, :ah, :vrrp, :igmp, :ipencap, :ipv4, :ipv6, :ospf, :gre, :cbt, :sctp, :all].collect do |proto| + newvalues(*[:tcp, :udp, :icmp, :"ipv6-icmp", :esp, :ah, :vrrp, :igmp, :ipencap, :ipv4, :ipv6, :ospf, :gre, :cbt, :sctp, :pim, :all].collect do |proto| [proto, "! #{proto}".to_sym] end.flatten) defaultto "tcp" diff --git a/spec/unit/puppet/type/firewall_spec.rb b/spec/unit/puppet/type/firewall_spec.rb index 38859f6..3e4804d 100755 --- a/spec/unit/puppet/type/firewall_spec.rb +++ b/spec/unit/puppet/type/firewall_spec.rb @@ -82,7 +82,7 @@ describe firewall do end describe ':proto' do - [:tcp, :udp, :icmp, :esp, :ah, :vrrp, :igmp, :ipencap, :ipv4, :ipv6, :ospf, :gre, :all].each do |proto| + [:tcp, :udp, :icmp, :esp, :ah, :vrrp, :igmp, :ipencap, :ipv4, :ipv6, :ospf, :gre, :pim, :all].each do |proto| it "should accept proto value #{proto}" do @resource[:proto] = proto @resource[:proto].should == proto