Merge "Revert "Minimize number of jobs needed to tag images""
This commit is contained in:
commit
30b9815161
@ -38,8 +38,7 @@
|
||||
when: pre_build_role is defined
|
||||
- name: Publish images
|
||||
block:
|
||||
- name: Publish Images with Latest and Commit Tags
|
||||
command: make images clean
|
||||
- command: make images clean
|
||||
args:
|
||||
chdir: "{{ makefile_chdir }}"
|
||||
environment:
|
||||
@ -48,7 +47,7 @@
|
||||
DOCKER_REGISTRY: "{{ docker_registry }}"
|
||||
GCP_SDK: "{{ gcp_sdk }}"
|
||||
IMAGE_PREFIX: "{{ image_prefix | default('airshipit') }}"
|
||||
IMAGE_TAG: "{{ image_tag | first | default('latest') }}"
|
||||
IMAGE_TAG: "{{ image_tag | default('latest') }}"
|
||||
LABEL: "{{ image_label | default('org.airshipit.build=community') }}"
|
||||
NO_PROXY: "{{ proxy.noproxy }}"
|
||||
PUSH_IMAGE: "false"
|
||||
@ -57,13 +56,4 @@
|
||||
USE_PROXY: "{{ proxy.enabled | lower }}"
|
||||
WORKDIR: "{{ image_work_dir | default('manifests') }}"
|
||||
PROFILE: "{{ image_profile_dir | default('') }}"
|
||||
- name: Publish the rest of the tags
|
||||
command: docker tag $DOCKER_REGISTRY/$IMAGE_PREFIX/$IMAGE_NAME:$IMAGE_TAG1 $DOCKER_REGISTRY/$IMAGE_PREFIX/$IMAGE_NAME:$IMAGE_TAG2
|
||||
environment:
|
||||
IMAGE_TAG1: "{{ image_tag | first | default('latest') }}"
|
||||
IMAGE_TAG2: "{{ item }}"
|
||||
DOCKER_REGISTRY: "{{ docker_registry }}"
|
||||
IMAGE_PREFIX: "{{ image_prefix | default('airshipit') }}"
|
||||
IMAGE_NAME: "{{ IMAGE_NAME | default('image-builder') }}"
|
||||
with_items: "{{ image_tag[1:] }}"
|
||||
become: True
|
||||
|
@ -53,7 +53,7 @@
|
||||
DOCKER_REGISTRY: "{{ docker_registry }}"
|
||||
GCP_SDK: "{{ gcp_sdk }}"
|
||||
IMAGE_PREFIX: "{{ image_prefix | default('airshipit') }}"
|
||||
IMAGE_TAG: "{{ image_tag | first | default('latest') }}"
|
||||
IMAGE_TAG: "{{ image_tag | default('latest') }}"
|
||||
LABEL: "{{ image_label | default('org.airshipit.build=community') }}"
|
||||
NO_PROXY: "{{ proxy.noproxy }}"
|
||||
PUSH_IMAGE: "true"
|
||||
@ -62,13 +62,4 @@
|
||||
USE_PROXY: "{{ proxy.enabled | lower }}"
|
||||
WORKDIR: "{{ image_work_dir | default('manifests') }}"
|
||||
PROFILE: "{{ image_profile_dir | default('') }}"
|
||||
- name: Publish the rest of the tags
|
||||
command: docker tag ${DOCKER_REGISTRY}/${IMAGE_PREFIX}/${IMAGE_NAME}:${IMAGE_TAG1} ${DOCKER_REGISTRY}/${IMAGE_PREFIX}/${IMAGE_NAME}:${IMAGE_TAG2} && docker push ${DOCKER_REGISTRY}/${IMAGE_PREFIX}/${IMAGE_NAME}
|
||||
environment:
|
||||
IMAGE_TAG1: "{{ image_tag | first | default('latest') }}"
|
||||
IMAGE_TAG2: "{{ item }}"
|
||||
DOCKER_REGISTRY: "{{ docker_registry }}"
|
||||
IMAGE_PREFIX: "{{ image_prefix | default('airshipit') }}"
|
||||
IMAGE_NAME: "{{ IMAGE_NAME | default('image-builder') }}"
|
||||
with_items: "{{ image_tag[1:] }}"
|
||||
become: True
|
||||
|
@ -44,9 +44,7 @@
|
||||
- name: image_builder_quay_creds
|
||||
secret: image_builder_quay_creds
|
||||
vars:
|
||||
image_tag:
|
||||
- "k8s-1.18-latest"
|
||||
- "k8s-1.18-{{ zuul.newrev }}"
|
||||
image_tag: "k8s-1.18-latest"
|
||||
|
||||
# Tag the 1.19 job with 1.19
|
||||
- job:
|
||||
@ -61,9 +59,21 @@
|
||||
- name: image_builder_quay_creds
|
||||
secret: image_builder_quay_creds
|
||||
vars:
|
||||
image_tag:
|
||||
- "k8s-1.19-latest"
|
||||
- "k8s-1.18-{{ zuul.newrev }}"
|
||||
image_tag: "k8s-1.19-latest"
|
||||
|
||||
# Tag the 1.18 job with zuul rev tag
|
||||
- job:
|
||||
name: airship-image-builder-publish-commit-k8s-1.18
|
||||
parent: airship-image-builder-publish-k8s-1.18
|
||||
vars:
|
||||
image_tag: "k8s-1.18-{{ zuul.newrev }}"
|
||||
|
||||
# Tag the 1.19 job with zuul rev tag
|
||||
- job:
|
||||
name: airship-image-builder-publish-commit-k8s-1.19
|
||||
parent: airship-image-builder-publish-k8s-1.19
|
||||
vars:
|
||||
image_tag: "k8s-1.19-{{ zuul.newrev }}"
|
||||
|
||||
- nodeset:
|
||||
name: airship-image-builder-single-node
|
||||
|
@ -12,7 +12,7 @@
|
||||
image_config_dir: manifests
|
||||
image_prefix: airshipit
|
||||
image_label: org.airshipit.build=community
|
||||
image_tag: [latest]
|
||||
image_tag: latest
|
||||
check:
|
||||
jobs:
|
||||
- airship-image-builder-build-k8s-1.18
|
||||
@ -26,6 +26,8 @@
|
||||
- airship-image-builder-upload-git-mirror
|
||||
- airship-image-builder-publish-k8s-1.18
|
||||
- airship-image-builder-publish-k8s-1.19
|
||||
- airship-image-builder-publish-commit-k8s-1.18
|
||||
- airship-image-builder-publish-commit-k8s-1.19
|
||||
tag:
|
||||
jobs:
|
||||
- airship-image-builder-upload-git-mirror
|
Loading…
Reference in New Issue
Block a user