Drop legacy-base from manila-test-image-build

We don't need the legacy and deprecated zuul-cloner
approach if we rewrite the job in native zuulv3 style.

Change-Id: Ifc6d592b8b7cf0e802ee11be837ebd4a3b55ea9b
Signed-off-by: Goutham Pacha Ravi <gouthampravi@gmail.com>
This commit is contained in:
Goutham Pacha Ravi 2020-08-17 09:56:22 -07:00
parent 037158d760
commit 1c16a41181
2 changed files with 8 additions and 49 deletions

View File

@ -1,8 +1,10 @@
- job:
name: manila-test-image-build
parent: legacy-base
parent: unittests
required-projects:
- openstack/manila-test-image
run: playbooks/manila-test-image-build/run.yaml
timeout: 3600
timeout: 1800
- project:
check:

View File

@ -1,49 +1,6 @@
- hosts: all
name: Autoconverted job legacy-manila-test-image-build from old job gate-manila-test-image-build
roles:
- bindep
tasks:
- name: Ensure legacy workspace directory
file:
path: '{{ ansible_user_dir }}/workspace'
state: directory
- shell:
cmd: |
set -e
set -x
CLONEMAP=`mktemp`
function cleanup {
# In cases where zuul-cloner is aborted during a git
# clone operation, git will remove the git work tree in
# its cleanup. The work tree in these jobs is the
# workspace directory, which means that subsequent
# jenkins post-build actions can not run because the
# workspace has been removed.
# To reduce the likelihood of this having an impact,
# recreate the workspace directory if needed
mkdir -p $WORKSPACE
rm -f $CLONEMAP
}
trap cleanup EXIT
cat > $CLONEMAP << EOF
clonemap:
- name: $ZUUL_PROJECT
dest: .
EOF
/usr/zuul-env/bin/zuul-cloner -m $CLONEMAP --cache-dir /opt/git \
https://opendev.org $ZUUL_PROJECT
executable: /bin/bash
chdir: '{{ ansible_user_dir }}/workspace'
environment: '{{ zuul | zuul_legacy_vars }}'
- shell:
cmd: |
set -e
set -x
./run-buildroot.sh
executable: /bin/bash
chdir: '{{ ansible_user_dir }}/workspace'
environment: '{{ zuul | zuul_legacy_vars }}'
- name: Build manila-test-image
command: bash -xe ./run-buildroot.sh
args:
chdir: '{{ zuul.project.src_dir }}'