From 0064d8955eaab96d0d4c1d034293164fd347ad6d Mon Sep 17 00:00:00 2001 From: Samuel Cassiba Date: Wed, 11 Apr 2018 22:14:54 -0700 Subject: [PATCH] Remove python_runtime references In Chef 13+, resource duplication behaves differently. By centralizing python_runtime to openstack-common, the resource executes once in a given Chef run, instead of attempting to reinstall python multiple times. Change-Id: I2e17d655c86fac63e02aaadf5321bc95e2c7aa0b --- recipes/neutron-fwaas-dashboard.rb | 6 ------ recipes/neutron-lbaas-dashboard.rb | 5 ----- spec/neutron-fwaas-dashboard_spec.rb | 4 ---- spec/neutron-lbaas-dashboard_spec.rb | 4 ---- 4 files changed, 19 deletions(-) diff --git a/recipes/neutron-fwaas-dashboard.rb b/recipes/neutron-fwaas-dashboard.rb index 1c57263..8b1b2cc 100644 --- a/recipes/neutron-fwaas-dashboard.rb +++ b/recipes/neutron-fwaas-dashboard.rb @@ -20,12 +20,6 @@ include_recipe 'openstack-dashboard::horizon' django_path = node['openstack']['dashboard']['django_path'] policy_file_path = node['openstack']['dashboard']['policy_files_path'] -# use system python for fwaas dashboard -python_runtime '2' do - provider :system - version '2.7' -end - python_package 'neutron-fwaas-dashboard' %w( diff --git a/recipes/neutron-lbaas-dashboard.rb b/recipes/neutron-lbaas-dashboard.rb index 2d3e1c2..bdb803d 100644 --- a/recipes/neutron-lbaas-dashboard.rb +++ b/recipes/neutron-lbaas-dashboard.rb @@ -19,11 +19,6 @@ include_recipe 'openstack-dashboard::horizon' django_path = node['openstack']['dashboard']['django_path'] -# use system python for lbaasv2 dashboard -python_runtime '2' do - provider :system -end - python_package 'neutron-lbaas-dashboard' do version node['openstack']['dashboard']['lbaas']['version'] notifies :run, 'execute[restore-selinux-context]', :immediately diff --git a/spec/neutron-fwaas-dashboard_spec.rb b/spec/neutron-fwaas-dashboard_spec.rb index c01ed7b..ff3ccf9 100644 --- a/spec/neutron-fwaas-dashboard_spec.rb +++ b/spec/neutron-fwaas-dashboard_spec.rb @@ -16,10 +16,6 @@ describe 'openstack-dashboard::neutron-fwaas-dashboard' do expect(chef_run).to include_recipe('openstack-dashboard::horizon') end - it do - expect(chef_run).to install_python_runtime('2') - end - it do expect(chef_run).to install_python_package('neutron-fwaas-dashboard') end diff --git a/spec/neutron-lbaas-dashboard_spec.rb b/spec/neutron-lbaas-dashboard_spec.rb index 44fb30c..37ac8db 100644 --- a/spec/neutron-lbaas-dashboard_spec.rb +++ b/spec/neutron-lbaas-dashboard_spec.rb @@ -16,10 +16,6 @@ describe 'openstack-dashboard::neutron-lbaas-dashboard' do expect(chef_run).to include_recipe('openstack-dashboard::horizon') end - it do - expect(chef_run).to install_python_runtime('2') - end - it do expect(chef_run).to install_python_package('neutron-lbaas-dashboard') end