Merge "Inherit pyvers from openstacklib::defaults"
This commit is contained in:
commit
309e673095
@ -22,18 +22,15 @@
|
||||
class ironic::params {
|
||||
include ::openstacklib::defaults
|
||||
|
||||
$pyvers = $::openstacklib::defaults::pyvers
|
||||
$pyver3 = $::openstacklib::defaults::pyver3
|
||||
|
||||
if ($::os_package_type == 'debian') {
|
||||
$pyvers = '3'
|
||||
$pyver3 = '3'
|
||||
$syslinux_path_custom = '/usr/lib/syslinux'
|
||||
} elsif ($::os['name'] == 'Fedora') or
|
||||
($::os['family'] == 'RedHat' and Integer.new($::os['release']['major']) > 7) {
|
||||
$pyvers = '3'
|
||||
$pyver3 = '3.6'
|
||||
$syslinux_path_custom = '/tftpboot'
|
||||
} else {
|
||||
$pyvers = ''
|
||||
$pyver3 = '2.7'
|
||||
$syslinux_path_custom = '/var/lib/tftpboot'
|
||||
}
|
||||
|
||||
|
@ -47,11 +47,7 @@ describe 'ironic::client' do
|
||||
let(:platform_params) do
|
||||
case facts[:osfamily]
|
||||
when 'Debian'
|
||||
if facts[:os_package_type] == 'debian'
|
||||
{ :client_package_name => 'python3-ironicclient' }
|
||||
else
|
||||
{ :client_package_name => 'python-ironicclient' }
|
||||
end
|
||||
when 'RedHat'
|
||||
{ :client_package_name => 'python-ironicclient' }
|
||||
end
|
||||
|
@ -26,7 +26,7 @@ describe 'ironic::drivers::drac' do
|
||||
it 'installs dracclient package' do
|
||||
is_expected.to contain_package('python-dracclient').with(
|
||||
:ensure => 'present',
|
||||
:name => 'python-dracclient',
|
||||
:name => platform_params[:dracclient_package_name],
|
||||
:tag => ['openstack', 'ironic-package'],
|
||||
)
|
||||
end
|
||||
@ -40,6 +40,16 @@ describe 'ironic::drivers::drac' do
|
||||
let (:facts) do
|
||||
facts.merge!(OSDefaults.get_facts())
|
||||
end
|
||||
|
||||
let (:platform_params) do
|
||||
case facts[:osfamily]
|
||||
when 'Debian'
|
||||
{ :dracclient_package_name => 'python3-dracclient' }
|
||||
when 'RedHat'
|
||||
{ :dracclient_package_name => 'python-dracclient' }
|
||||
end
|
||||
end
|
||||
|
||||
it_behaves_like 'ironic drac driver'
|
||||
end
|
||||
end
|
||||
|
@ -36,7 +36,7 @@ describe 'ironic::drivers::ilo' do
|
||||
it 'installs proliantutils package' do
|
||||
is_expected.to contain_package('python-proliantutils').with(
|
||||
:ensure => 'present',
|
||||
:name => 'python-proliantutils',
|
||||
:name => platform_params[:proliantutils_package_name],
|
||||
:tag => ['openstack', 'ironic-package'],
|
||||
)
|
||||
end
|
||||
@ -65,6 +65,16 @@ describe 'ironic::drivers::ilo' do
|
||||
let (:facts) do
|
||||
facts.merge!(OSDefaults.get_facts())
|
||||
end
|
||||
|
||||
let (:platform_params) do
|
||||
case facts[:osfamily]
|
||||
when 'Debian'
|
||||
{ :proliantutils_package_name => 'python3-proliantutils' }
|
||||
when 'RedHat'
|
||||
{ :proliantutils_package_name => 'python-proliantutils' }
|
||||
end
|
||||
end
|
||||
|
||||
it_behaves_like 'ironic ilo driver'
|
||||
end
|
||||
end
|
||||
|
@ -34,7 +34,7 @@ describe 'ironic::drivers::redfish' do
|
||||
it 'installs sushy package' do
|
||||
is_expected.to contain_package('python-sushy').with(
|
||||
:ensure => 'present',
|
||||
:name => 'python-sushy',
|
||||
:name => platform_params[:sushy_package_name],
|
||||
:tag => ['openstack', 'ironic-package'],
|
||||
)
|
||||
end
|
||||
@ -59,6 +59,16 @@ describe 'ironic::drivers::redfish' do
|
||||
let (:facts) do
|
||||
facts.merge!(OSDefaults.get_facts())
|
||||
end
|
||||
|
||||
let (:platform_params) do
|
||||
case facts[:osfamily]
|
||||
when 'Debian'
|
||||
{ :sushy_package_name => 'python3-sushy' }
|
||||
when 'RedHat'
|
||||
{ :sushy_package_name => 'python-sushy' }
|
||||
end
|
||||
end
|
||||
|
||||
it_behaves_like 'ironic redfish driver'
|
||||
end
|
||||
end
|
||||
|
@ -263,13 +263,8 @@ describe 'ironic' do
|
||||
let :platform_params do
|
||||
case facts[:osfamily]
|
||||
when 'Debian'
|
||||
if facts[:os_package_type] == 'debian' then
|
||||
ironic_lib_pkgname = 'python3-ironic-lib'
|
||||
else
|
||||
ironic_lib_pkgname = 'python-ironic-lib'
|
||||
end
|
||||
{ :common_package_name => 'ironic-common',
|
||||
:lib_package_name => ironic_lib_pkgname }
|
||||
:lib_package_name => 'python3-ironic-lib' }
|
||||
when 'RedHat'
|
||||
{ :common_package_name => 'openstack-ironic-common',
|
||||
:lib_package_name => 'python-ironic-lib' }
|
||||
|
@ -35,7 +35,7 @@ describe 'ironic::inspector::client' do
|
||||
it 'installs ironic inspector client package' do
|
||||
is_expected.to contain_package('python-ironic-inspector-client').with(
|
||||
:ensure => 'present',
|
||||
:name => 'python-ironic-inspector-client',
|
||||
:name => platform_params[:ironic_inspector_client_package_name],
|
||||
:tag => ['openstack', 'ironic-support-package'],
|
||||
)
|
||||
end
|
||||
@ -49,6 +49,15 @@ describe 'ironic::inspector::client' do
|
||||
facts.merge!(OSDefaults.get_facts())
|
||||
end
|
||||
|
||||
let (:platform_params) do
|
||||
case facts[:osfamily]
|
||||
when 'Debian'
|
||||
{ :ironic_inspector_client_package_name => 'python3-ironic-inspector-client' }
|
||||
when 'RedHat'
|
||||
{ :ironic_inspector_client_package_name => 'python-ironic-inspector-client' }
|
||||
end
|
||||
end
|
||||
|
||||
it_configures 'inspector client'
|
||||
end
|
||||
end
|
||||
|
@ -94,7 +94,7 @@ describe 'ironic::wsgi::apache' do
|
||||
:httpd_service_name => 'apache2',
|
||||
:httpd_ports_file => '/etc/apache2/ports.conf',
|
||||
:wsgi_script_path => '/usr/lib/cgi-bin/ironic',
|
||||
:wsgi_script_source => '/usr/lib/python2.7/dist-packages/ironic/api/app.wsgi',
|
||||
:wsgi_script_source => '/usr/lib/python3/dist-packages/ironic/api/app.wsgi',
|
||||
}
|
||||
when 'RedHat'
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user