diff --git a/manifests/params.pp b/manifests/params.pp index a0df1bb..08d5e13 100644 --- a/manifests/params.pp +++ b/manifests/params.pp @@ -2,13 +2,7 @@ # class panko::params { include ::openstacklib::defaults - - if ($::os_package_type == 'debian') or ($::os['name'] == 'Fedora') or - ($::os['family'] == 'RedHat' and Integer.new($::os['release']['major']) > 7) { - $pyvers = '3' - } else { - $pyvers = '' - } + $pyvers = $::openstacklib::defaults::pyvers $client_package_name = "python${pyvers}-pankoclient" $group = 'panko' diff --git a/spec/classes/panko_client_spec.rb b/spec/classes/panko_client_spec.rb index 0eca2ce..88a3466 100644 --- a/spec/classes/panko_client_spec.rb +++ b/spec/classes/panko_client_spec.rb @@ -27,11 +27,7 @@ describe 'panko::client' do let(:platform_params) do case facts[:osfamily] when 'Debian' - if facts[:os_package_type] == 'debian' - { :client_package_name => 'python3-pankoclient' } - else - { :client_package_name => 'python-pankoclient' } - end + { :client_package_name => 'python3-pankoclient' } when 'RedHat' { :client_package_name => 'python-pankoclient' } end