Get rid of the $pyvers variable
Since everyone has switched to Python3, it's time for the removal of the $pyvers variable. Change-Id: I056a6d5acc8312db2405795e2a52e60a0b902383
This commit is contained in:
parent
8522ba8556
commit
b52c14963e
@ -30,7 +30,7 @@ class neutron::agents::bigswitch (
|
|||||||
fail("Unsupported osfamily ${::osfamily}")
|
fail("Unsupported osfamily ${::osfamily}")
|
||||||
}
|
}
|
||||||
|
|
||||||
ensure_packages("python${neutron::params::pyvers}-networking-bigswitch",
|
ensure_packages('python3-networking-bigswitch',
|
||||||
{
|
{
|
||||||
ensure => $package_ensure,
|
ensure => $package_ensure,
|
||||||
tag => ['openstack', 'neutron-package'],
|
tag => ['openstack', 'neutron-package'],
|
||||||
|
@ -4,17 +4,16 @@
|
|||||||
#
|
#
|
||||||
class neutron::params {
|
class neutron::params {
|
||||||
include openstacklib::defaults
|
include openstacklib::defaults
|
||||||
$pyvers = $::openstacklib::defaults::pyvers
|
|
||||||
|
|
||||||
$client_package = "python${pyvers}-neutronclient"
|
$client_package = 'python3-neutronclient'
|
||||||
$ovs_agent_service = 'neutron-openvswitch-agent'
|
$ovs_agent_service = 'neutron-openvswitch-agent'
|
||||||
$destroy_patch_ports_service = 'neutron-destroy-patch-ports'
|
$destroy_patch_ports_service = 'neutron-destroy-patch-ports'
|
||||||
$linuxbridge_agent_service = 'neutron-linuxbridge-agent'
|
$linuxbridge_agent_service = 'neutron-linuxbridge-agent'
|
||||||
$cisco_config_file = '/etc/neutron/plugins/cisco/cisco_plugins.ini'
|
$cisco_config_file = '/etc/neutron/plugins/cisco/cisco_plugins.ini'
|
||||||
$opencontrail_plugin_package = 'neutron-plugin-contrail'
|
$opencontrail_plugin_package = 'neutron-plugin-contrail'
|
||||||
$opencontrail_config_file = '/etc/neutron/plugins/opencontrail/ContrailPlugin.ini'
|
$opencontrail_config_file = '/etc/neutron/plugins/opencontrail/ContrailPlugin.ini'
|
||||||
$ovn_plugin_package = "python${pyvers}-networking-ovn"
|
$ovn_plugin_package = 'python3-networking-ovn'
|
||||||
$vpp_plugin_package = "python${pyvers}-networking-vpp"
|
$vpp_plugin_package = 'python3-networking-vpp'
|
||||||
$vpp_agent_service = 'neutron-vpp-agent'
|
$vpp_agent_service = 'neutron-vpp-agent'
|
||||||
$nuage_config_file = '/etc/neutron/plugins/nuage/plugin.ini'
|
$nuage_config_file = '/etc/neutron/plugins/nuage/plugin.ini'
|
||||||
$dhcp_agent_service = 'neutron-dhcp-agent'
|
$dhcp_agent_service = 'neutron-dhcp-agent'
|
||||||
@ -25,15 +24,15 @@ class neutron::params {
|
|||||||
$ovn_metadata_agent_service = 'networking-ovn-metadata-agent'
|
$ovn_metadata_agent_service = 'networking-ovn-metadata-agent'
|
||||||
$bgp_dragent_service = 'neutron-bgp-dragent'
|
$bgp_dragent_service = 'neutron-bgp-dragent'
|
||||||
$bagpipe_bgp_package = 'openstack-bagpipe-bgp'
|
$bagpipe_bgp_package = 'openstack-bagpipe-bgp'
|
||||||
$bgpvpn_bagpipe_package = "python${pyvers}-networking-bagpipe"
|
$bgpvpn_bagpipe_package = 'python3-networking-bagpipe'
|
||||||
$bgpvpn_bagpipe_service = 'bagpipe-bgp'
|
$bgpvpn_bagpipe_service = 'bagpipe-bgp'
|
||||||
$bgpvpn_plugin_package = "python${pyvers}-networking-bgpvpn"
|
$bgpvpn_plugin_package = 'python3-networking-bgpvpn'
|
||||||
$l2gw_agent_service = 'neutron-l2gw-agent'
|
$l2gw_agent_service = 'neutron-l2gw-agent'
|
||||||
$nsx_plugin_package = 'vmware-nsx'
|
$nsx_plugin_package = 'vmware-nsx'
|
||||||
$nsx_config_file = '/etc/neutron/plugins/vmware/nsx.ini'
|
$nsx_config_file = '/etc/neutron/plugins/vmware/nsx.ini'
|
||||||
$sfc_package = "python${pyvers}-networking-sfc"
|
$sfc_package = 'python3-networking-sfc'
|
||||||
$group = 'neutron'
|
$group = 'neutron'
|
||||||
$mlnx_agent_package = "python${pyvers}-networking-mlnx"
|
$mlnx_agent_package = 'python3-networking-mlnx'
|
||||||
$eswitchd_service = 'eswitchd'
|
$eswitchd_service = 'eswitchd'
|
||||||
|
|
||||||
if($::osfamily == 'Redhat') {
|
if($::osfamily == 'Redhat') {
|
||||||
@ -64,8 +63,8 @@ class neutron::params {
|
|||||||
$metering_agent_package = 'openstack-neutron-metering-agent'
|
$metering_agent_package = 'openstack-neutron-metering-agent'
|
||||||
$vpnaas_agent_package = 'openstack-neutron-vpnaas'
|
$vpnaas_agent_package = 'openstack-neutron-vpnaas'
|
||||||
$l2gw_agent_package = 'openstack-neutron-l2gw-agent'
|
$l2gw_agent_package = 'openstack-neutron-l2gw-agent'
|
||||||
$l2gw_package = "python${pyvers}-networking-l2gw"
|
$l2gw_package = 'python3-networking-l2gw'
|
||||||
$ovn_metadata_agent_package = "python${pyvers}-networking-ovn-metadata-agent"
|
$ovn_metadata_agent_package = 'python3-networking-ovn-metadata-agent'
|
||||||
$dynamic_routing_package = false
|
$dynamic_routing_package = false
|
||||||
$bgp_dragent_package = 'openstack-neutron-bgp-dragent'
|
$bgp_dragent_package = 'openstack-neutron-bgp-dragent'
|
||||||
$openswan_package = 'libreswan'
|
$openswan_package = 'libreswan'
|
||||||
@ -75,10 +74,10 @@ class neutron::params {
|
|||||||
$fwaas_package = 'openstack-neutron-fwaas'
|
$fwaas_package = 'openstack-neutron-fwaas'
|
||||||
$neutron_wsgi_script_path = '/var/www/cgi-bin/neutron'
|
$neutron_wsgi_script_path = '/var/www/cgi-bin/neutron'
|
||||||
$neutron_wsgi_script_source = '/usr/bin/neutron-api'
|
$neutron_wsgi_script_source = '/usr/bin/neutron-api'
|
||||||
$networking_baremetal_package = "python${pyvers}-networking-baremetal"
|
$networking_baremetal_package = 'python3-networking-baremetal'
|
||||||
$networking_baremetal_agent_package = "python${pyvers}-ironic-neutron-agent"
|
$networking_baremetal_agent_package = 'python3-ironic-neutron-agent'
|
||||||
$networking_baremetal_agent_service = 'ironic-neutron-agent'
|
$networking_baremetal_agent_service = 'ironic-neutron-agent'
|
||||||
$networking_ansible_package = "python${pyvers}-networking-ansible"
|
$networking_ansible_package = 'python3-networking-ansible'
|
||||||
$mlnx_agent_service = 'neutron-mlnx-agent'
|
$mlnx_agent_service = 'neutron-mlnx-agent'
|
||||||
} elsif($::osfamily == 'Debian') {
|
} elsif($::osfamily == 'Debian') {
|
||||||
$nobody_user_group = 'nogroup'
|
$nobody_user_group = 'nogroup'
|
||||||
@ -100,7 +99,7 @@ class neutron::params {
|
|||||||
$api_service_name = false
|
$api_service_name = false
|
||||||
$rpc_package_name = false
|
$rpc_package_name = false
|
||||||
$rpc_service_name = false
|
$rpc_service_name = false
|
||||||
$dynamic_routing_package = "python${pyvers}-neutron-dynamic-routing"
|
$dynamic_routing_package = 'python3-neutron-dynamic-routing'
|
||||||
}
|
}
|
||||||
$bgp_dragent_package = 'neutron-bgp-dragent'
|
$bgp_dragent_package = 'neutron-bgp-dragent'
|
||||||
$ovs_agent_package = 'neutron-openvswitch-agent'
|
$ovs_agent_package = 'neutron-openvswitch-agent'
|
||||||
@ -115,14 +114,14 @@ class neutron::params {
|
|||||||
$nvp_server_package = 'neutron-plugin-nicira'
|
$nvp_server_package = 'neutron-plugin-nicira'
|
||||||
$dhcp_agent_package = 'neutron-dhcp-agent'
|
$dhcp_agent_package = 'neutron-dhcp-agent'
|
||||||
$metering_agent_package = 'neutron-metering-agent'
|
$metering_agent_package = 'neutron-metering-agent'
|
||||||
$vpnaas_agent_package = "python${pyvers}-neutron-vpnaas"
|
$vpnaas_agent_package = 'python3-neutron-vpnaas'
|
||||||
$openswan_package = 'strongswan'
|
$openswan_package = 'strongswan'
|
||||||
$libreswan_package = false
|
$libreswan_package = false
|
||||||
$metadata_agent_package = 'neutron-metadata-agent'
|
$metadata_agent_package = 'neutron-metadata-agent'
|
||||||
$l3_agent_package = 'neutron-l3-agent'
|
$l3_agent_package = 'neutron-l3-agent'
|
||||||
$fwaas_package = "python${pyvers}-neutron-fwaas"
|
$fwaas_package = 'python3-neutron-fwaas'
|
||||||
$l2gw_agent_package = 'neutron-l2gateway-agent'
|
$l2gw_agent_package = 'neutron-l2gateway-agent'
|
||||||
$l2gw_package = "python${pyvers}-networking-l2gw"
|
$l2gw_package = 'python3-networking-l2gw'
|
||||||
$neutron_wsgi_script_path = '/usr/lib/cgi-bin/neutron'
|
$neutron_wsgi_script_path = '/usr/lib/cgi-bin/neutron'
|
||||||
$neutron_wsgi_script_source = '/usr/bin/neutron-api'
|
$neutron_wsgi_script_source = '/usr/bin/neutron-api'
|
||||||
$mlnx_agent_service = 'neutron-plugin-mlnx-agent'
|
$mlnx_agent_service = 'neutron-plugin-mlnx-agent'
|
||||||
|
@ -117,24 +117,10 @@ describe 'neutron::agents::ml2::mlnx' do
|
|||||||
:mlnx_agent_service => 'neutron-plugin-mlnx-agent'
|
:mlnx_agent_service => 'neutron-plugin-mlnx-agent'
|
||||||
}
|
}
|
||||||
when 'RedHat'
|
when 'RedHat'
|
||||||
if facts[:operatingsystem] == 'Fedora'
|
{
|
||||||
{
|
:mlnx_agent_package => 'python3-networking-mlnx',
|
||||||
:mlnx_agent_package => 'python3-networking-mlnx',
|
:mlnx_agent_service => 'neutron-mlnx-agent'
|
||||||
:mlnx_agent_service => 'neutron-mlnx-agent'
|
}
|
||||||
}
|
|
||||||
else
|
|
||||||
if facts[:operatingsystemmajrelease] > '7'
|
|
||||||
{
|
|
||||||
:mlnx_agent_package => 'python3-networking-mlnx',
|
|
||||||
:mlnx_agent_service => 'neutron-mlnx-agent'
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
:mlnx_agent_package => 'python-networking-mlnx',
|
|
||||||
:mlnx_agent_service => 'neutron-mlnx-agent'
|
|
||||||
}
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -101,18 +101,8 @@ describe 'neutron::agents::ml2::networking_baremetal' do
|
|||||||
let (:platform_params) do
|
let (:platform_params) do
|
||||||
case facts[:osfamily]
|
case facts[:osfamily]
|
||||||
when 'RedHat'
|
when 'RedHat'
|
||||||
if facts[:operatingsystem] == 'Fedora'
|
{ :networking_baremetal_agent_package => 'python3-ironic-neutron-agent',
|
||||||
{ :networking_baremetal_agent_package => 'python3-ironic-neutron-agent',
|
:networking_baremetal_agent_service => 'ironic-neutron-agent' }
|
||||||
:networking_baremetal_agent_service => 'ironic-neutron-agent' }
|
|
||||||
else
|
|
||||||
if facts[:operatingsystemmajrelease] > '7'
|
|
||||||
{ :networking_baremetal_agent_package => 'python3-ironic-neutron-agent',
|
|
||||||
:networking_baremetal_agent_service => 'ironic-neutron-agent' }
|
|
||||||
else
|
|
||||||
{ :networking_baremetal_agent_package => 'python2-ironic-neutron-agent',
|
|
||||||
:networking_baremetal_agent_service => 'ironic-neutron-agent' }
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
case facts[:osfamily]
|
case facts[:osfamily]
|
||||||
|
@ -100,18 +100,8 @@ describe 'neutron::agents::ml2::vpp' do
|
|||||||
{ :vpp_plugin_package => 'python3-networking-vpp',
|
{ :vpp_plugin_package => 'python3-networking-vpp',
|
||||||
:vpp_agent_service => 'neutron-vpp-agent' }
|
:vpp_agent_service => 'neutron-vpp-agent' }
|
||||||
when 'RedHat'
|
when 'RedHat'
|
||||||
if facts[:operatingsystem] == 'Fedora'
|
{ :vpp_plugin_package => 'python3-networking-vpp',
|
||||||
{ :vpp_plugin_package => 'python3-networking-vpp',
|
:vpp_agent_service => 'neutron-vpp-agent' }
|
||||||
:vpp_agent_service => 'neutron-vpp-agent' }
|
|
||||||
else
|
|
||||||
if facts[:operatingsystemmajrelease] > '7'
|
|
||||||
{ :vpp_plugin_package => 'python3-networking-vpp',
|
|
||||||
:vpp_agent_service => 'neutron-vpp-agent' }
|
|
||||||
else
|
|
||||||
{ :vpp_plugin_package => 'python-networking-vpp',
|
|
||||||
:vpp_agent_service => 'neutron-vpp-agent' }
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -120,18 +120,8 @@ describe 'neutron::agents::ovn_metadata' do
|
|||||||
:ovn_metadata_agent_service => 'networking-ovn-metadata-agent'
|
:ovn_metadata_agent_service => 'networking-ovn-metadata-agent'
|
||||||
}
|
}
|
||||||
when 'RedHat'
|
when 'RedHat'
|
||||||
if facts[:operatingsystem] == 'Fedora'
|
{ :ovn_metadata_agent_package => 'python3-networking-ovn-metadata-agent',
|
||||||
{ :ovn_metadata_agent_package => 'python3-networking-ovn-metadata-agent',
|
:ovn_metadata_agent_service => 'networking-ovn-metadata-agent' }
|
||||||
:ovn_metadata_agent_service => 'networking-ovn-metadata-agent' }
|
|
||||||
else
|
|
||||||
if facts[:operatingsystemmajrelease] > '7'
|
|
||||||
{ :ovn_metadata_agent_package => 'python3-networking-ovn-metadata-agent',
|
|
||||||
:ovn_metadata_agent_service => 'networking-ovn-metadata-agent' }
|
|
||||||
else
|
|
||||||
{ :ovn_metadata_agent_package => 'python-networking-ovn-metadata-agent',
|
|
||||||
:ovn_metadata_agent_service => 'networking-ovn-metadata-agent' }
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -29,15 +29,7 @@ describe 'neutron::client' do
|
|||||||
when 'Debian'
|
when 'Debian'
|
||||||
{ :client_package => 'python3-neutronclient' }
|
{ :client_package => 'python3-neutronclient' }
|
||||||
when 'RedHat'
|
when 'RedHat'
|
||||||
if facts[:operatingsystem] == 'Fedora'
|
{ :client_package => 'python3-neutronclient' }
|
||||||
{ :client_package => 'python3-neutronclient' }
|
|
||||||
else
|
|
||||||
if facts[:operatingsystemmajrelease] > '7'
|
|
||||||
{ :client_package => 'python3-neutronclient' }
|
|
||||||
else
|
|
||||||
{ :client_package => 'python-neutronclient' }
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -45,15 +45,7 @@ describe 'neutron::plugins::ml2::bagpipe' do
|
|||||||
when 'Debian'
|
when 'Debian'
|
||||||
{ :bagpipe_package_name => 'python3-networking-bagpipe' }
|
{ :bagpipe_package_name => 'python3-networking-bagpipe' }
|
||||||
when 'RedHat'
|
when 'RedHat'
|
||||||
if facts[:operatingsystem] == 'Fedora'
|
{ :bagpipe_package_name => 'python3-networking-bagpipe' }
|
||||||
{ :bagpipe_package_name => 'python3-networking-bagpipe' }
|
|
||||||
else
|
|
||||||
if facts[:operatingsystemmajrelease] > '7'
|
|
||||||
{ :bagpipe_package_name => 'python3-networking-bagpipe' }
|
|
||||||
else
|
|
||||||
{ :bagpipe_package_name => 'python-networking-bagpipe' }
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
it_behaves_like 'neutron plugin bagpipe ml2'
|
it_behaves_like 'neutron plugin bagpipe ml2'
|
||||||
|
@ -73,15 +73,7 @@ describe 'neutron::plugins::ml2::networking_ansible' do
|
|||||||
let (:platform_params) do
|
let (:platform_params) do
|
||||||
case facts[:osfamily]
|
case facts[:osfamily]
|
||||||
when 'RedHat'
|
when 'RedHat'
|
||||||
if facts[:operatingsystem] == 'Fedora'
|
{ :networking_ansible_package => 'python3-networking-ansible'}
|
||||||
{ :networking_ansible_package => 'python3-networking-ansible'}
|
|
||||||
else
|
|
||||||
if facts[:operatingsystemmajrelease] > '7'
|
|
||||||
{ :networking_ansible_package => 'python3-networking-ansible'}
|
|
||||||
else
|
|
||||||
{ :networking_ansible_package => 'python2-networking-ansible'}
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
case facts[:osfamily]
|
case facts[:osfamily]
|
||||||
|
@ -38,16 +38,10 @@ describe 'neutron::plugins::ml2::networking_baremetal' do
|
|||||||
end
|
end
|
||||||
let (:platform_params) do
|
let (:platform_params) do
|
||||||
case facts[:osfamily]
|
case facts[:osfamily]
|
||||||
|
when 'Debian'
|
||||||
|
{ :networking_baremetal_package => 'python3-networking-baremetal'}
|
||||||
when 'RedHat'
|
when 'RedHat'
|
||||||
if facts[:operatingsystem] == 'Fedora'
|
{ :networking_baremetal_package => 'python3-networking-baremetal'}
|
||||||
{ :networking_baremetal_package => 'python3-networking-baremetal'}
|
|
||||||
else
|
|
||||||
if facts[:operatingsystemmajrelease] > '7'
|
|
||||||
{ :networking_baremetal_package => 'python3-networking-baremetal'}
|
|
||||||
else
|
|
||||||
{ :networking_baremetal_package => 'python2-networking-baremetal'}
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
case facts[:osfamily]
|
case facts[:osfamily]
|
||||||
|
@ -80,15 +80,7 @@ describe 'neutron::services::bgpvpn' do
|
|||||||
when 'Debian'
|
when 'Debian'
|
||||||
{ :bgpvpn_package_name => 'python3-networking-bgpvpn' }
|
{ :bgpvpn_package_name => 'python3-networking-bgpvpn' }
|
||||||
when 'RedHat'
|
when 'RedHat'
|
||||||
if facts[:operatingsystem] == 'Fedora'
|
{ :bgpvpn_package_name => 'python3-networking-bgpvpn' }
|
||||||
{ :bgpvpn_package_name => 'python3-networking-bgpvpn' }
|
|
||||||
else
|
|
||||||
if facts[:operatingsystemmajrelease] > '7'
|
|
||||||
{ :bgpvpn_package_name => 'python3-networking-bgpvpn' }
|
|
||||||
else
|
|
||||||
{ :bgpvpn_package_name => 'python-networking-bgpvpn' }
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
it_behaves_like 'neutron bgpvpn service plugin'
|
it_behaves_like 'neutron bgpvpn service plugin'
|
||||||
|
@ -104,15 +104,7 @@ describe 'neutron::services::l2gw' do
|
|||||||
when 'Debian'
|
when 'Debian'
|
||||||
{ :l2gw_agent_package_name => 'python3-networking-l2gw' }
|
{ :l2gw_agent_package_name => 'python3-networking-l2gw' }
|
||||||
when 'RedHat'
|
when 'RedHat'
|
||||||
if facts[:operatingsystem] == 'Fedora'
|
{ :l2gw_agent_package_name => 'python3-networking-l2gw' }
|
||||||
{ :l2gw_agent_package_name => 'python3-networking-l2gw' }
|
|
||||||
else
|
|
||||||
if facts[:operatingsystemmajrelease] > '7'
|
|
||||||
{ :l2gw_agent_package_name => 'python3-networking-l2gw' }
|
|
||||||
else
|
|
||||||
{ :l2gw_agent_package_name => 'python-networking-l2gw' }
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -86,15 +86,7 @@ describe 'neutron::services::sfc' do
|
|||||||
when 'Debian'
|
when 'Debian'
|
||||||
{ :sfc_package_name => 'python3-networking-sfc' }
|
{ :sfc_package_name => 'python3-networking-sfc' }
|
||||||
when 'RedHat'
|
when 'RedHat'
|
||||||
if facts[:operatingsystem] == 'Fedora'
|
{ :sfc_package_name => 'python3-networking-sfc' }
|
||||||
{ :sfc_package_name => 'python3-networking-sfc' }
|
|
||||||
else
|
|
||||||
if facts[:operatingsystemmajrelease] > '7'
|
|
||||||
{ :sfc_package_name => 'python3-networking-sfc' }
|
|
||||||
else
|
|
||||||
{ :sfc_package_name => 'python-networking-sfc' }
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
it_behaves_like 'neutron sfc service plugin'
|
it_behaves_like 'neutron sfc service plugin'
|
||||||
|
Loading…
Reference in New Issue
Block a user