Prep $PROJECT and upper constraints for install

Before we can start enforcing constraints during tox runs we need to
ensure that the upper constraints from the requirements repo is in place
and up to date with the correct ref which may be latest $BRANCH or
$ZUUL_REF. Use zuul-cloner to ensure the state of both the project under
test and the constraints from the requirements repo.

To make use of this projects can update their tox targets to look for an
upper constraints file in the root dir of the project and have pip honor
those constraints when present.

Change-Id: I2829ba1bb0ce22b0f18080a1dc4ca7b1c77ce0e3
This commit is contained in:
Clark Boylan 2015-07-13 18:10:20 -07:00
parent d6f21629c3
commit 82bf7a71df
2 changed files with 23 additions and 1 deletions

View File

@ -7,7 +7,7 @@
- timestamps - timestamps
builders: builders:
- zuul-git-prep - zuul-git-prep-upper-constraints
- install-distro-packages - install-distro-packages
- mysql-prep - mysql-prep
- pgsql-prep - pgsql-prep

View File

@ -39,6 +39,28 @@
/usr/zuul-env/bin/zuul-cloner -m $CLONEMAP --cache-dir /opt/git \ /usr/zuul-env/bin/zuul-cloner -m $CLONEMAP --cache-dir /opt/git \
git://git.openstack.org $ZUUL_PROJECT git://git.openstack.org $ZUUL_PROJECT
- builder:
name: zuul-git-prep-upper-constraints
builders:
- shell: |
#!/bin/bash -xe
CLONEMAP=`mktemp`
REQS_DIR=`mktemp -d`
function cleanup {
rm -rf $CLONEMAP $REQS_DIR
}
trap cleanup EXIT
cat > $CLONEMAP << EOF
clonemap:
- name: $ZUUL_PROJECT
dest: .
- name: openstack/requirements
dest: $REQS_DIR
EOF
/usr/zuul-env/bin/zuul-cloner -m $CLONEMAP --cache-dir /opt/git \
git://git.openstack.org $ZUUL_PROJECT openstack/requirements
cp $REQS_DIR/upper-constraints.txt ./
- builder: - builder:
name: zuul-git-branch-prep name: zuul-git-branch-prep
builders: builders: