diff --git a/attributes/default.rb b/attributes/default.rb index d958a760..31db030e 100644 --- a/attributes/default.rb +++ b/attributes/default.rb @@ -26,6 +26,9 @@ default['openstack']['common']['custom_template_banner'] = ' # Do not edit, changes will be overwritten ' +# version for python-openstackclient +default['openstack']['common']['client_version'] = '3.4.1' + # OpenStack services and their project names default['openstack']['common']['services'] = { 'bare-metal' => 'ironic', diff --git a/recipes/client.rb b/recipes/client.rb index 6df4ace7..9662ccea 100644 --- a/recipes/client.rb +++ b/recipes/client.rb @@ -21,5 +21,5 @@ python_runtime '2' python_package 'python-openstackclient' do - version '2.6' + version node['openstack']['common']['client_version'] end diff --git a/spec/client_spec.rb b/spec/client_spec.rb index 8f28c6dd..a3cf789e 100644 --- a/spec/client_spec.rb +++ b/spec/client_spec.rb @@ -9,13 +9,13 @@ describe 'openstack-common::client' do runner.converge(described_recipe) end - it 'installs the latest python 2' do + it do expect(chef_run).to install_python_runtime('2') end - it 'installs python-openstackclient 2.6' do + it do expect(chef_run).to install_python_package('python-openstackclient') - .with(version: '2.6') + .with(version: '3.4.1') end end end