Merge "Debian is using python3-magnumclient"
This commit is contained in:
commit
09e5ab90e0
@ -4,6 +4,13 @@
|
||||
#
|
||||
class magnum::params {
|
||||
include ::openstacklib::defaults
|
||||
|
||||
if ($::os_package_type == 'debian') {
|
||||
$pyvers = '3'
|
||||
} else {
|
||||
$pyvers = ''
|
||||
}
|
||||
|
||||
$group = 'magnum'
|
||||
case $::osfamily {
|
||||
'RedHat': {
|
||||
@ -24,7 +31,7 @@ class magnum::params {
|
||||
# service names
|
||||
$api_service = 'magnum-api'
|
||||
$conductor_service = 'magnum-conductor'
|
||||
$client_package = 'python-magnumclient'
|
||||
$client_package = "python${pyvers}-magnumclient"
|
||||
}
|
||||
default: {
|
||||
fail("Unsupported osfamily: ${::osfamily} operatingsystem")
|
||||
|
@ -10,7 +10,7 @@ describe 'magnum::client' do
|
||||
it 'installs magnum client package' do
|
||||
is_expected.to contain_package('python-magnumclient').with(
|
||||
:ensure => 'present',
|
||||
:name => platform_params[:client_package],
|
||||
:name => platform_params[:client_package_name],
|
||||
:tag => 'openstack',
|
||||
)
|
||||
end
|
||||
@ -27,9 +27,13 @@ describe 'magnum::client' do
|
||||
let(:platform_params) do
|
||||
case facts[:osfamily]
|
||||
when 'Debian'
|
||||
{ :client_package => 'python-magnumclient' }
|
||||
if facts[:os_package_type] == 'debian'
|
||||
{ :client_package_name => 'python3-magnumclient' }
|
||||
else
|
||||
{ :client_package_name => 'python-magnumclient' }
|
||||
end
|
||||
when 'RedHat'
|
||||
{ :client_package => 'python2-magnumclient' }
|
||||
{ :client_package_name => 'python2-magnumclient' }
|
||||
end
|
||||
end
|
||||
it_configures 'magnum client'
|
||||
|
Loading…
x
Reference in New Issue
Block a user