diff --git a/manifests/agents/ml2/ovs.pp b/manifests/agents/ml2/ovs.pp index a832a275c..d4a7ab489 100644 --- a/manifests/agents/ml2/ovs.pp +++ b/manifests/agents/ml2/ovs.pp @@ -179,6 +179,18 @@ # final egress tables direct output flows for unicast traffic. (boolean value) # Defaults to $::os_service_default # +# [*igmp_snooping_enable*] +# (Optional) Enable IGMP snooping for integration bridge. If this +# option is set to True, support for Internet Group Management +# Protocol (IGMP) is enabled in integration bridge. +# Setting this option to True will also enable Open vSwitch +# mcast-snooping-disable-flood-unregistered flag. This option will +# disable flooding of unregistered multicast packets to all ports. +# The switch will send unregistered multicast packets only to ports +# connected to multicast routers. This option is used by the ML2/OVS +# mechanism driver for Neutron. +# Defaults to $::os_service_default +# # DEPRECATED # # [*of_interface*] @@ -219,6 +231,7 @@ class neutron::agents::ml2::ovs ( $minimize_polling = $::os_service_default, $tunnel_csum = $::os_service_default, $explicitly_egress_direct = $::os_service_default, + $igmp_snooping_enable = $::os_service_default, # DEPRECATED $of_interface = undef, ) { @@ -331,6 +344,7 @@ class neutron::agents::ml2::ovs ( 'ovs/ovsdb_interface': value => $ovsdb_interface; 'ovs/of_interface': value => $of_interface; 'securitygroup/enable_security_group': value => $enable_security_group; + 'ovs/igmp_snooping_enable': value => $igmp_snooping_enable; } if $firewall_driver { diff --git a/spec/classes/neutron_agents_ml2_ovs_spec.rb b/spec/classes/neutron_agents_ml2_ovs_spec.rb index 0a24c726d..f554ae029 100644 --- a/spec/classes/neutron_agents_ml2_ovs_spec.rb +++ b/spec/classes/neutron_agents_ml2_ovs_spec.rb @@ -66,6 +66,7 @@ describe 'neutron::agents::ml2::ovs' do should contain_neutron_agent_ovs('ovs/tun_peer_patch_port').with_ensure('absent') should contain_neutron_agent_ovs('agent/tunnel_types').with_ensure('absent') should contain_neutron_agent_ovs('agent/explicitly_egress_direct').with_value(['']) + should contain_neutron_agent_ovs('ovs/igmp_snooping_enable').with_value('') end it 'installs neutron ovs agent package' do @@ -387,6 +388,17 @@ describe 'neutron::agents::ml2::ovs' do should contain_neutron_agent_ovs('agent/explicitly_egress_direct').with_value(true) end end + + context 'with IGMP snooping enabled' do + before :each do + params.merge!(:igmp_snooping_enable => true) + end + + it 'configure neutron/plugins/ml2/ml2_conf.ini' do + should contain_neutron_agent_ovs('ovs/igmp_snooping_enable').with_value(true) + end + end + end on_supported_os({