Devstack: refactor neutron projects install

Changing ownership to the packages installed
under devstack/src, since the pip install is
done by root.

Change-Id: If923071e1e3a744488925d609acf3d5518931b07
Signed-off-by: Michal Kelner Mishali <mkelnermishal@vmware.com>
This commit is contained in:
Michal Kelner Mishali 2018-05-07 09:43:15 +03:00
parent 6c80fa0c4f
commit 5fbca9dc96
1 changed files with 12 additions and 17 deletions

View File

@ -30,24 +30,19 @@ function _nsxv_ini_set {
} }
function install_neutron_projects { function install_neutron_projects {
# TODO(boden): find a better way to use master branch dependencies in devstack pkg_list="networking-l2gw networking-sfc neutron-lbaas neutron-fwaas neutron-dynamic-routing neutron-vpnaas vmware-nsxlib"
sudo rm -rf /usr/local/lib/python2.7/dist-packages/networking_l2gw* for pkg in `echo $pkg_list`
sudo pip install -e "git+https://git.openstack.org/openstack/networking-l2gw#egg=networking_l2gw" do
sudo rm -rf /usr/local/lib/python2.7/dist-packages/networking_sfc* pkg_renamed=`echo $pkg | sed 's/-/_/g'`
sudo pip install -e "git+https://git.openstack.org/openstack/networking-sfc#egg=networking_sfc" sudo rm -rf /usr/local/lib/python2.7/dist-packages/${pkg_renamed}*
sudo rm -rf /usr/local/lib/python2.7/dist-packages/neutron_lbaas* sudo rm -rf ./src/${pkg_renamed}*
sudo pip install -e "git+https://git.openstack.org/openstack/neutron-lbaas#egg=neutron_lbaas" sudo pip install -e "git+https://git.openstack.org/openstack/${pkg}#egg=${pkg_renamed}"
sudo rm -rf /usr/local/lib/python2.7/dist-packages/neutron_fwaas* sudo chown -R ${USER}:${USER} src/${pkg}
sudo pip install -e "git+https://git.openstack.org/openstack/neutron-fwaas#egg=neutron_fwaas" done
sudo rm -rf /usr/local/lib/python2.7/dist-packages/neutron_dynamic_routing*
sudo pip install -e "git+https://git.openstack.org/openstack/neutron-dynamic-routing#egg=neutron_dynamic_routing"
sudo rm -rf /usr/local/lib/python2.7/dist-packages/neutron_vpnaas*
sudo pip install -e "git+https://git.openstack.org/openstack/neutron-vpnaas#egg=neutron_vpnaas"
sudo rm -rf /usr/local/lib/python2.7/dist-packages/vmware_nsxlib*
sudo pip install -e "git+https://git.openstack.org/openstack/vmware-nsxlib#egg=vmware_nsxlib"
sudo rm -rf /usr/local/lib/python2.7/dist-packages/neutron sudo rm -rf /usr/local/lib/python2.7/dist-packages/neutron
sudo rm -rf /usr/local/lib/python2.7/dist-packages/neutron.egg* sudo rm -rf /usr/local/lib/python2.7/dist-packages/neutron.egg*
sudo pip install -e "git+https://git.openstack.org/openstack/neutron#egg=neutron" sudo pip install -e "git+https://git.openstack.org/openstack/neutron#egg=neutron"
sudo chown -R ${USER}:${USER} src/neutron
} }
function nsxv_configure_service { function nsxv_configure_service {