]> git.apps.os.sepia.ceph.com Git - ceph-build.git/commitdiff
add the build script for ceph-tag 169/head
authorAlfredo Deza <adeza@redhat.com>
Wed, 28 Oct 2015 11:30:48 +0000 (07:30 -0400)
committerAlfredo Deza <adeza@redhat.com>
Wed, 28 Oct 2015 11:30:48 +0000 (07:30 -0400)
Signed-off-by: Alfredo Deza <adeza@redhat.com>
ceph-tag/build/build [new file with mode: 0644]

diff --git a/ceph-tag/build/build b/ceph-tag/build/build
new file mode 100644 (file)
index 0000000..ee5f33d
--- /dev/null
@@ -0,0 +1,26 @@
+#!/bin/bash
+
+set -ex
+
+# Create the virtualenv
+virtualenv venv
+. venv/bin/activate
+
+# Define and ensure the PIP cache
+PIP_SDIST_INDEX="$HOME/.cache/pip"
+mkdir -p $PIP_SDIST_INDEX
+
+# The setup for this job ensures that a copy of ceph-build will be available
+# for this script
+
+# 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/bin/pip install --find-links="file://$PIP_SDIST_INDEX" --no-index ansible; then
+    venv/bin/pip install --exists-action=i --download-directory="$PIP_SDIST_INDEX" ansible
+    venv/bin/pip install --find-links="file://$PIP_SDIST_INDEX" --no-index ansible
+fi
+
+# run ansible to do all the tagging and release specifying
+# a local connection and 'localhost' as the host where to execute
+cd "$WORKSPACE/ceph-build/ansible/"
+ansible-playbook -i "localhost," -c local release.yml --extra-vars="version=$VERSION branch=$BRANCH release=stable clean=true"