Debian is using python3-zaqarclient

Change-Id: Iedf33a913bd6854f418d11d655204245f20d684c
This commit is contained in:
zhubingbing 2018-04-12 11:51:04 +08:00
parent cfbe1326bb
commit e2ca4a65d9
2 changed files with 18 additions and 3 deletions

View File

@ -5,7 +5,13 @@
class zaqar::params {
include ::openstacklib::defaults
$client_package_name = 'python-zaqarclient'
if ($::os_package_type == 'debian') {
$pyvers = '3'
} else {
$pyvers = ''
}
$client_package_name = "python${pyvers}-zaqarclient"
$group = 'zaqar'
case $::osfamily {

View File

@ -24,8 +24,17 @@ describe 'zaqar::client' do
facts.merge!(OSDefaults.get_facts())
end
let :platform_params do
{ :client_package_name => 'python-zaqarclient' }
let(:platform_params) do
case facts[:osfamily]
when 'Debian'
if facts[:os_package_type] == 'debian'
{ :client_package_name => 'python3-zaqarclient' }
else
{ :client_package_name => 'python-zaqarclient' }
end
when 'RedHat'
{ :client_package_name => 'python-zaqarclient' }
end
end
it_behaves_like 'zaqar client'