Install python3-openstackclient in Fedora or RedHat > 7
Fedora repo [1] has python3 packages, start consuming those. [1] http://trunk.rdoproject.org/fedora/current/ Change-Id: I8e2ec45e38275fb0910f5921662cb7cf865edd0a
This commit is contained in:
		@@ -5,8 +5,11 @@
 | 
				
			|||||||
#
 | 
					#
 | 
				
			||||||
class openstacklib::params {
 | 
					class openstacklib::params {
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  $openstackclient_package_name = $::os_package_type ? {
 | 
					  if ($::os_package_type == 'debian') or ($::os['name'] == 'Fedora') or
 | 
				
			||||||
    'debian' => 'python3-openstackclient',
 | 
					     ($::os['family'] == 'RedHat' and Integer.new($::os['release']['major']) > 7) {
 | 
				
			||||||
    default  => 'python-openstackclient',
 | 
					    $pyvers = '3'
 | 
				
			||||||
 | 
					  } else {
 | 
				
			||||||
 | 
					    $pyvers = ''
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					  $openstackclient_package_name = "python${pyvers}-openstackclient"
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -35,7 +35,8 @@ describe 'openstacklib::openstackclient' do
 | 
				
			|||||||
      end
 | 
					      end
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      let(:platform_params) do
 | 
					      let(:platform_params) do
 | 
				
			||||||
        if facts[:os_package_type] == 'debian' then
 | 
					        if facts[:os_package_type] == 'debian' or (facts[:os_package_type] == 'rpm' \
 | 
				
			||||||
 | 
					            and facts[:operatingsystemrelease].to_i > 7) then
 | 
				
			||||||
          openstackclient_package_name = 'python3-openstackclient'
 | 
					          openstackclient_package_name = 'python3-openstackclient'
 | 
				
			||||||
        else
 | 
					        else
 | 
				
			||||||
          openstackclient_package_name = 'python-openstackclient'
 | 
					          openstackclient_package_name = 'python-openstackclient'
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user