project-config/jenkins/jobs/release-jobs.yaml
Doug Hellmann bf142fa7b7 make release script repo cloning function more resilient
The release scripts had been assuming that a valid gerrit user was
always configured already, but this is not necessarily the case on all
nodes. Now that the constraint update job has moved to the proposal
nodes, we need to make the cloner code try to configure the gerrit user
if "git review -s" fails. We can't always take that step because it
would result in using the wrong user on the signing node and when users
run the scripts by hand (as we still do frequently to recover from
failures).

Change-Id: Ife8108f0bff4be9ab63befc5eff4289be78316f7
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2016-12-21 15:14:00 -05:00

53 lines
1.5 KiB
YAML

- job:
name: tag-releases
description: Apply tags to repositories based on changes in deliverables files, then create requested branches.
node: signing
builders:
- gerrit-git-prep
- revoke-sudo
- shell: |
#!/bin/bash -ex
# Tell the launchpad script run from release.sh where it's
# credentials file is.
export LP_CREDS_FILE=$HOME/.launchpadlib/creds
# Pass the location of the openstack/releases repo to
# release_from_yaml.sh explicitly so it knows where to scan to
# look for modified files.
/usr/local/jenkins/slave_scripts/release-tools/release_from_yaml.sh $(pwd)
# After we have tagged, create any new branches.
/usr/local/jenkins/slave_scripts/release-tools/branch_from_yaml.sh $(pwd)
publishers:
- console-log
# This job runs after a repository has been tagged to update the
# upper-constraints.txt list in the openstack/requirements repository.
- job-template:
name: 'propose-{name}-update-constraints'
node: proposal
builders:
- print-template-name:
template-name: "{template-name}"
- gerrit-git-prep
- revoke-sudo
- shell: |
#!/bin/bash
set -x
# Save the version that was just tagged by parsing
# ref/tags/VALUE to get VALUE.
VERSION=$(echo $ZUUL_REF | cut -f3 -d/)
/usr/local/jenkins/slave_scripts/release-tools/update_constraints.sh $VERSION
publishers:
- test-results
- console-log