From 244d48d209b3a99e22cbdb4e97d73363b5b65d1d Mon Sep 17 00:00:00 2001 From: Samuel Cassiba Date: Mon, 10 Dec 2018 08:11:08 -0800 Subject: [PATCH] Pin setuptools and wheels packages In order to maintain consistency for pip versions, align pip, wheels, and setuptools. Use OSA as a basis for consistency between deploy projects. Change-Id: I573bd84e1f15b6e9bda8ebb1d8e12fa66970757a --- recipes/default.rb | 17 ++++++++++------- recipes/python.rb | 9 ++++++++- 2 files changed, 18 insertions(+), 8 deletions(-) diff --git a/recipes/default.rb b/recipes/default.rb index ab927256..7735729f 100644 --- a/recipes/default.rb +++ b/recipes/default.rb @@ -18,13 +18,6 @@ # limitations under the License. # -# install a python -python_runtime '2' do - provider :system - # Workaround for https://github.com/poise/poise-python/issues/133 - pip_version '18.0' -end - platform_options = node['openstack']['common']['platform'] case node['platform_family'] when 'debian' @@ -127,6 +120,16 @@ when 'rhel' end end +# install a python +python_runtime '2' do + provider :system + # Workaround for https://github.com/poise/poise-python/issues/133 + pip_version '18.0' + # Align with eg. OpenStack-Ansible (https://git.openstack.org/cgit/openstack/openstack-ansible/tree/global-requirement-pins.txt) + setuptools_version '40.0.0' + wheel_version '0.31.1' +end + if node['openstack']['databag_type'] == 'vault' chef_gem 'chef-vault' do version node['openstack']['vault_gem_version'] diff --git a/recipes/python.rb b/recipes/python.rb index 357eab45..f5374eb0 100644 --- a/recipes/python.rb +++ b/recipes/python.rb @@ -20,13 +20,20 @@ # install system packages for Ubuntu/Debian case node['platform_family'] -when 'debian', 'ubuntu' +when 'debian' python_runtime '3.5' do provider :system + # Align with eg. OpenStack-Ansible (https://git.openstack.org/cgit/openstack/openstack-ansible/tree/global-requirement-pins.txt) + pip_version '18.0' + setuptools_version '40.0.0' + wheel_version '0.31.1' end # use Software Collections for CentOS/RHEL when 'rhel' python_runtime '3.5' do provider :scl + pip_version '18.0' + setuptools_version '40.0.0' + wheel_version '0.31.1' end end