Conditionally override PyPI for reqs integration
* devstack-vm-gate-wrap.sh: In preparation for performing integration testing of the openstack/requirements global list on changes to requirements and jeepyb/pypi-mirror, allow the combination of ZUUL_PROJECT and DEVSTACK_GATE_REQS_INTEGRATION envvars to determine whether to override the PyPI URL and use the openstack mirror. Change-Id: I21fe53b7a17594f1d7f20f1407d0c19d11ad11be
This commit is contained in:
@@ -197,23 +197,26 @@ function setup_host {
|
||||
sudo usermod -a -G vz stack
|
||||
fi
|
||||
|
||||
cat <<EOF > /tmp/pydistutils.cfg
|
||||
if [ "$DEVSTACK_GATE_REQS_INTEGRATION" -eq "0" \
|
||||
-o "$ZUUL_PROJECT" != "openstack/requirements" ]; then
|
||||
cat <<EOF > /tmp/pydistutils.cfg
|
||||
[easy_install]
|
||||
index_url = http://pypi.openstack.org/openstack
|
||||
EOF
|
||||
cat <<EOF > /tmp/pip.conf
|
||||
cat <<EOF > /tmp/pip.conf
|
||||
[global]
|
||||
index-url = http://pypi.openstack.org/openstack
|
||||
EOF
|
||||
cp /tmp/pydistutils.cfg ~/.pydistutils.cfg
|
||||
cp /tmp/pydistutils.cfg ~stack/.pydistutils.cfg
|
||||
sudo cp /tmp/pydistutils.cfg ~root/.pydistutils.cfg
|
||||
mkdir -p ~/.pip
|
||||
mkdir -p ~stack/.pip
|
||||
sudo -u root mkdir -p ~root/.pip
|
||||
cp /tmp/pip.conf ~/.pip/pip.conf
|
||||
cp /tmp/pip.conf ~stack/.pip/pip.conf
|
||||
sudo -u root cp /tmp/pip.conf ~root/.pip/pip.conf
|
||||
cp /tmp/pydistutils.cfg ~/.pydistutils.cfg
|
||||
cp /tmp/pydistutils.cfg ~stack/.pydistutils.cfg
|
||||
sudo cp /tmp/pydistutils.cfg ~root/.pydistutils.cfg
|
||||
mkdir -p ~/.pip
|
||||
mkdir -p ~stack/.pip
|
||||
sudo -u root mkdir -p ~root/.pip
|
||||
cp /tmp/pip.conf ~/.pip/pip.conf
|
||||
cp /tmp/pip.conf ~stack/.pip/pip.conf
|
||||
sudo -u root cp /tmp/pip.conf ~root/.pip/pip.conf
|
||||
fi
|
||||
|
||||
# Disable detailed logging as we return to the main script
|
||||
set +o xtrace
|
||||
@@ -461,6 +464,9 @@ export DEVSTACK_GATE_TEMPEST_TESTR_FULL=${DEVSTACK_GATE_TEMPEST_TESTR_FULL:-0}
|
||||
# Set to 1 to run all tempest tests
|
||||
export DEVSTACK_GATE_TEMPEST_ALL=${DEVSTACK_GATE_TEMPEST_ALL:-0}
|
||||
|
||||
# Set to 1 if running the openstack/requirements integration test
|
||||
export DEVSTACK_GATE_REQS_INTEGRATION=${DEVSTACK_GATE_REQS_INTEGRATION:-0}
|
||||
|
||||
if ! function_exists "gate_hook"; then
|
||||
# the command we use to run the gate
|
||||
function gate_hook {
|
||||
|
||||
Reference in New Issue
Block a user