zuul-operator/.zuul.yaml
James E. Blair 0366b867bf Upload release images on tag
This uploads release images to dockerhub when we tag the repo.

Change-Id: Ic44a9d29a1e888d8d7874205b0025f286912b5e8
2021-04-10 18:37:28 -07:00

113 lines
3.9 KiB
YAML

- job:
description: Operator integration tests
name: zuul-operator-functional
abstract: true
run:
- playbooks/zuul-operator-functional/run.yaml
- playbooks/zuul-operator-functional/test.yaml
post-run: playbooks/zuul-operator-functional/post.yaml
vars:
# We disable userland-proxy to enable scheduler deployement to connect to the gearman service
# see: https://github.com/eclipse/che/issues/8134
docker_userland_proxy: false
container_runtime: docker
- job:
description: Operator integration tests with Kubernetes
name: zuul-operator-functional-k8s
parent: zuul-operator-functional
pre-run: playbooks/zuul-operator-functional/pre-k8s.yaml
nodeset: ubuntu-bionic
vars:
namespace: 'default'
withCertManager: true
- job:
description: Image and buildset registry job
name: zuul-operator-build-image
parent: opendev-build-docker-image
allowed-projects: zuul/zuul-operator
requires:
- zuul-container-image
- zuul-registry-container-image
- nodepool-container-image
provides:
- zuul-operator-container-image
vars: &image_vars
zuul_work_dir: "{{ zuul.projects['opendev.org/zuul/zuul-operator'].src_dir }}"
docker_images:
- context: .
dockerfile: build/Dockerfile
repository: zuul/zuul-operator
tags:
# If zuul.tag is defined: [ '3', '3.19', '3.19.0' ]. Only works for 3-component tags.
# Otherwise: ['latest']
"{{ zuul.tag is defined | ternary([zuul.get('tag', '').split('.')[0], '.'.join(zuul.get('tag', '').split('.')[:2]), zuul.get('tag', '')], ['latest']) }}"
- secret:
name: zuul-operator-dockerhub
data:
username: zuulzuul
password: !encrypted/pkcs1-oaep
- QVrNMxcxfu35rLxt2m/ZGWPRHDm0rbw/rybpkbuL8B7v0CvJjgsLxfZ2uonMRINk53gex
TN9Y6vdM3YUu/Bdu4Z7cTKV+ohBRdCbEzJAVHJGclYRAFVzAMLDgKWZRFNrJVY1/0U9AZ
a4F32AS8hWAdH03Ntv77cK+NX/y0pSAySin7o45XrHAA21vAASp9PSGLCSCB5pVfHELyR
lgpu4+NMh2ocbbDwzQFAJbYgb60OYRYlsvI4ECCvDDm2Jxma6iOYnSe62E8v/K7fhFzVr
orBystkKaOy1154aGYTajtR0vebTGw6XJt4SYID3dHKS9XTwjpTEJySfFtSRDHDi0lhdN
gSS7ZojBlOrj1/a/Oddca9iGgjqLaC2iOJGsABXXP14WambZNvDG07/eEaS2dhV745k06
HPdapriUCuTBqivSkItighYYB8eh9LkqwVxXJ/feyewMERasWkKPDkT/mX5+R1KJCTnwS
xmEvngPk5gLwpDexLL+nmNahYNbz7alzFUGCSR7jTLORZUgimGDzfaguTHZNhzb4jE9kU
0s5nzOti9LdQNCkKVAvRCsOyp7+U9zvf6LHQhO35ivW3vrSmEfyqQqUVdJMBHhBE8M0jj
AYLhYdFc748RTCVJzka6uAQ69QJuv0wSP0+MHKy39OrnOSDZUGm1dkeTQwqpWA=
- job:
description: Build Docker images and upload to Docker Hub.
name: zuul-operator-upload-image
parent: opendev-upload-docker-image
allowed-projects: zuul/zuul-operator
secrets:
name: docker_credentials
secret: zuul-operator-dockerhub
pass-to-parent: true
requires:
- zuul-container-image
- zuul-registry-container-image
- nodepool-container-image
provides:
- zuul-operator-container-image
vars: *image_vars
- job:
description: Promote previously uploaded images.
name: zuul-operator-promote-image
parent: opendev-promote-docker-image
allowed-projects: zuul/zuul-operator
secrets:
name: docker_credentials
secret: zuul-operator-dockerhub
pass-to-parent: true
nodeset:
nodes: []
vars: *image_vars
- project:
check:
jobs:
- zuul-operator-build-image
- zuul-operator-functional-k8s:
dependencies: zuul-operator-build-image
gate:
jobs:
- zuul-operator-upload-image
- zuul-operator-functional-k8s:
dependencies: zuul-operator-upload-image
promote:
jobs:
- zuul-operator-promote-image
release:
jobs:
- zuul-operator-upload-image:
vars:
<<: *image_vars
upload_docker_image_promote: false