Fix name of networking-ansible/baremetal package
We should install python3-* instead of python2-* in CentOS8. This change fixes the remaining usage of python2-* left for netwokring-ansible and networking-baremetal. Change-Id: I136a81cc857130b3befa5df204525bfa6c6f0206
This commit is contained in:
parent
9c3bf1a7d0
commit
34b5036ed8
@ -173,7 +173,7 @@ Use user_domain_name instead')
|
||||
}
|
||||
}
|
||||
|
||||
package { 'python2-ironic-neutron-agent':
|
||||
package { 'python-ironic-neutron-agent':
|
||||
ensure => $package_ensure,
|
||||
name => $::neutron::params::networking_baremetal_agent_package,
|
||||
tag => ['openstack', 'neutron-package'],
|
||||
|
@ -75,8 +75,8 @@ class neutron::params {
|
||||
$fwaas_package = 'openstack-neutron-fwaas'
|
||||
$neutron_wsgi_script_path = '/var/www/cgi-bin/neutron'
|
||||
$neutron_wsgi_script_source = '/usr/bin/neutron-api'
|
||||
$networking_baremetal_package = 'python2-networking-baremetal'
|
||||
$networking_baremetal_agent_package = 'python2-ironic-neutron-agent'
|
||||
$networking_baremetal_package = "python${pyvers}-networking-baremetal"
|
||||
$networking_baremetal_agent_package = "python${pyvers}-ironic-neutron-agent"
|
||||
$networking_baremetal_agent_service = 'ironic-neutron-agent'
|
||||
$networking_ansible_package = "python${pyvers}-networking-ansible"
|
||||
$mlnx_agent_service = 'neutron-mlnx-agent'
|
||||
|
@ -45,9 +45,10 @@ class neutron::plugins::ml2::networking_ansible(
|
||||
fail("Unsupported osfamily ${::osfamily}")
|
||||
}
|
||||
|
||||
ensure_resource('package', 'python2-networking-ansible',
|
||||
ensure_resource('package', 'python-networking-ansible',
|
||||
{
|
||||
ensure => $package_ensure,
|
||||
name => $::neutron::params::networking_ansible_package,
|
||||
tag => ['openstack', 'neutron-plugin-ml2-package']
|
||||
}
|
||||
)
|
||||
|
@ -21,7 +21,7 @@ class neutron::plugins::ml2::networking_baremetal(
|
||||
# Drivers are only packaged for RedHat at this time
|
||||
fail("Unsupported osfamily ${::osfamily}")
|
||||
} else {
|
||||
package { 'python2-networking-baremetal':
|
||||
package { 'python-networking-baremetal':
|
||||
ensure => $package_ensure,
|
||||
name => $::neutron::params::networking_baremetal_package,
|
||||
tag => ['openstack', 'neutron-plugin-ml2-package'],
|
||||
|
@ -54,13 +54,13 @@ describe 'neutron::agents::ml2::networking_baremetal' do
|
||||
end
|
||||
|
||||
it 'installs ironic-neutron-agent agent package' do
|
||||
should contain_package('python2-ironic-neutron-agent').with(
|
||||
should contain_package('python-ironic-neutron-agent').with(
|
||||
:name => platform_params[:networking_baremetal_agent_package],
|
||||
:ensure => p[:package_ensure],
|
||||
:tag => ['openstack', 'neutron-package'],
|
||||
)
|
||||
should contain_package('python2-ironic-neutron-agent').that_requires('Anchor[neutron::install::begin]')
|
||||
should contain_package('python2-ironic-neutron-agent').that_notifies('Anchor[neutron::install::end]')
|
||||
should contain_package('python-ironic-neutron-agent').that_requires('Anchor[neutron::install::begin]')
|
||||
should contain_package('python-ironic-neutron-agent').that_notifies('Anchor[neutron::install::end]')
|
||||
end
|
||||
|
||||
it 'configures networking-baremetal ironic-neutron-agent service' do
|
||||
@ -101,8 +101,18 @@ describe 'neutron::agents::ml2::networking_baremetal' do
|
||||
let (:platform_params) do
|
||||
case facts[:osfamily]
|
||||
when 'RedHat'
|
||||
{ :networking_baremetal_agent_package => 'python2-ironic-neutron-agent',
|
||||
:networking_baremetal_agent_service => 'ironic-neutron-agent' }
|
||||
if facts[:operatingsystem] == 'Fedora'
|
||||
{ :networking_baremetal_agent_package => 'python3-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
|
||||
case facts[:osfamily]
|
||||
|
@ -30,14 +30,14 @@ describe 'neutron::plugins::ml2::networking_ansible' do
|
||||
|
||||
it { should contain_class('neutron::params') }
|
||||
|
||||
it 'installs networking-ansible python2-networking-ansible package' do
|
||||
should contain_package('python2-networking-ansible').with(
|
||||
it 'installs networking-ansible python-networking-ansible package' do
|
||||
should contain_package('python-networking-ansible').with(
|
||||
:name => platform_params[:networking_ansible_package],
|
||||
:ensure => p[:package_ensure],
|
||||
:tag => ['openstack', 'neutron-plugin-ml2-package'],
|
||||
)
|
||||
should contain_package('python2-networking-ansible').that_requires('Anchor[neutron::install::begin]')
|
||||
should contain_package('python2-networking-ansible').that_notifies('Anchor[neutron::config::end]')
|
||||
should contain_package('python-networking-ansible').that_requires('Anchor[neutron::install::begin]')
|
||||
should contain_package('python-networking-ansible').that_notifies('Anchor[neutron::config::end]')
|
||||
end
|
||||
|
||||
it 'should configure non-host config' do
|
||||
@ -73,7 +73,15 @@ describe 'neutron::plugins::ml2::networking_ansible' do
|
||||
let (:platform_params) do
|
||||
case facts[:osfamily]
|
||||
when 'RedHat'
|
||||
{ :networking_ansible_package => 'python2-networking-ansible'}
|
||||
if facts[:operatingsystem] == 'Fedora'
|
||||
{ :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
|
||||
case facts[:osfamily]
|
||||
|
@ -18,14 +18,14 @@ describe 'neutron::plugins::ml2::networking_baremetal' do
|
||||
|
||||
it { should contain_class('neutron::params') }
|
||||
|
||||
it 'installs networking-baremetal python2-networking-baremetal package' do
|
||||
should contain_package('python2-networking-baremetal').with(
|
||||
it 'installs networking-baremetal python-networking-baremetal package' do
|
||||
should contain_package('python-networking-baremetal').with(
|
||||
:name => platform_params[:networking_baremetal_package],
|
||||
:ensure => p[:package_ensure],
|
||||
:tag => ['openstack', 'neutron-plugin-ml2-package'],
|
||||
)
|
||||
should contain_package('python2-networking-baremetal').that_requires('Anchor[neutron::install::begin]')
|
||||
should contain_package('python2-networking-baremetal').that_notifies('Anchor[neutron::config::end]')
|
||||
should contain_package('python-networking-baremetal').that_requires('Anchor[neutron::install::begin]')
|
||||
should contain_package('python-networking-baremetal').that_notifies('Anchor[neutron::config::end]')
|
||||
end
|
||||
end
|
||||
|
||||
@ -39,7 +39,15 @@ describe 'neutron::plugins::ml2::networking_baremetal' do
|
||||
let (:platform_params) do
|
||||
case facts[:osfamily]
|
||||
when 'RedHat'
|
||||
{ :networking_baremetal_package => 'python2-networking-baremetal'}
|
||||
if facts[:operatingsystem] == 'Fedora'
|
||||
{ :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
|
||||
case facts[:osfamily]
|
||||
|
Loading…
Reference in New Issue
Block a user