Browse Source

Fix python2 compatible ipa creations

Old default versions of setuptools may have issues parsinq requirements.
To keep compatibility with Python 2.x we need to upgrade setuptools in
virtualenvs still using that version.

Change-Id: I61b77ceb6c58b5db451ccbbdfec9d92b4fa5bc89
changes/04/788804/2
Riccardo Pittau 3 weeks ago
parent
commit
69107b7d04
1 changed files with 5 additions and 2 deletions
  1. +5
    -2
      dib/ironic-python-agent-ramdisk/install.d/ironic-python-agent-ramdisk-source-install/60-ironic-python-agent-ramdisk-install

+ 5
- 2
dib/ironic-python-agent-ramdisk/install.d/ironic-python-agent-ramdisk-source-install/60-ironic-python-agent-ramdisk-install View File

@ -48,8 +48,11 @@ if [ $HAS_PIP == "False" ]; then
$VENVDIR/bin/pip install "pip==$REQUIRED_PIP_STR"
fi
# Upgrade setuptools package for openSuse
if [ "$DISTRO_NAME" == "opensuse" ]; then
# Upgrade setuptools package for openSuse and in virtualenvs using Python 2.x
# NOTE(rpittau): if we want to keep compatibility with Python 2.x, we need to
# upgrade setuptools in the virtualenv as the default installed has issues
# when parsing requirements.
if [ "$DISTRO_NAME" == "opensuse" ] || [ $IPA_PYTHON_VERSION == 2 ]; then
$VENVDIR/bin/pip install -U setuptools
fi


Loading…
Cancel
Save