From 87e4a687d5e4f34f09b795b954b485eae7cba198 Mon Sep 17 00:00:00 2001 From: Andrew Schoen Date: Mon, 9 Nov 2015 10:10:05 -0600 Subject: [PATCH] explicitly sepcify a chacractl version to install This fixes a bug where we don't get newer versions of chacractl installed when we want it because of the use of the pip cache. Signed-off-by: Andrew Schoen --- ceph-build-next/build/setup | 8 +++++--- ceph-deploy/build/setup | 8 +++++--- ceph-release-rpm/build/build | 8 +++++--- 3 files changed, 15 insertions(+), 9 deletions(-) diff --git a/ceph-build-next/build/setup b/ceph-build-next/build/setup index e972345a..4ac14309 100644 --- a/ceph-build-next/build/setup +++ b/ceph-build-next/build/setup @@ -74,11 +74,13 @@ VENV="$WORKSPACE/venv/bin" PIP_SDIST_INDEX="$HOME/.cache/pip" mkdir -p $PIP_SDIST_INDEX +CHACRACTL_VERSION="chacractl>=0.0.4" + # Install the package by trying with the cache first, otherwise doing a download only, and then # trying to install from the cache again. -if ! $VENV/pip install --find-links="file://$PIP_SDIST_INDEX" --no-index chacractl; then - $VENV/pip install --exists-action=i --download-directory="$PIP_SDIST_INDEX" chacractl - $VENV/pip install --find-links="file://$PIP_SDIST_INDEX" --no-index chacractl +if ! $VENV/pip install --find-links="file://$PIP_SDIST_INDEX" --no-index $CHACRACTL_VERSION; then + $VENV/pip install --exists-action=i --download-directory="$PIP_SDIST_INDEX" $CHACRACTL_VERSION + $VENV/pip install --find-links="file://$PIP_SDIST_INDEX" --no-index $CHACRACTL_VERSION fi # create the .chacractl config file diff --git a/ceph-deploy/build/setup b/ceph-deploy/build/setup index 2947ff4e..bd7c065e 100644 --- a/ceph-deploy/build/setup +++ b/ceph-deploy/build/setup @@ -25,11 +25,13 @@ source $WORKSPACE/venv/bin/activate PIP_SDIST_INDEX="$HOME/.cache/pip" mkdir -p $PIP_SDIST_INDEX +CHACRACTL_VERSION="chacractl>=0.0.4" + # Install the package by trying with the cache first, otherwise doing a download only, and then # trying to install from the cache again. -if ! pip install --find-links="file://$PIP_SDIST_INDEX" --no-index chacractl; then - pip install --exists-action=i --download-directory="$PIP_SDIST_INDEX" chacractl - pip install --find-links="file://$PIP_SDIST_INDEX" --no-index chacractl +if ! pip install --find-links="file://$PIP_SDIST_INDEX" --no-index $CHACRACTL_VERSION; then + pip install --exists-action=i --download-directory="$PIP_SDIST_INDEX" $CHACRACTL_VERSION + pip install --find-links="file://$PIP_SDIST_INDEX" --no-index $CHACRACTL_VERSION fi # create the .chacractl config file diff --git a/ceph-release-rpm/build/build b/ceph-release-rpm/build/build index 21f4bf2a..0291106d 100644 --- a/ceph-release-rpm/build/build +++ b/ceph-release-rpm/build/build @@ -20,11 +20,13 @@ VENV="$WORKSPACE/venv/bin" PIP_SDIST_INDEX="$HOME/.cache/pip" mkdir -p $PIP_SDIST_INDEX +CHACRACTL_VERSION="chacractl>=0.0.4" + # Install the package by trying with the cache first, otherwise doing a download only, and then # trying to install from the cache again. -if ! $VENV/pip install --find-links="file://$PIP_SDIST_INDEX" --no-index chacractl; then - $VENV/pip install --exists-action=i --download-directory="$PIP_SDIST_INDEX" chacractl - $VENV/pip install --find-links="file://$PIP_SDIST_INDEX" --no-index chacractl +if ! $VENV/pip install --find-links="file://$PIP_SDIST_INDEX" --no-index $CHACRACTL_VERSION; then + $VENV/pip install --exists-action=i --download-directory="$PIP_SDIST_INDEX" $CHACRACTL_VERSION + $VENV/pip install --find-links="file://$PIP_SDIST_INDEX" --no-index $CHACRACTL_VERSION fi # create the .chacractl config file -- 2.39.5