It seems likely that new versions of buildx are uploading manifests in
the OCI manifest format, which needs to be explicitly accepted in the
headers.
Change-Id: Ie2b908b7019389087ea37058bed15760619e48c6
We've seen a case where we can still push and pull tags from dockerhub,
but the web UI and API seem out of sync with the actual registry. In
this case, we would like to continue, even though it will leave some
unused tags in the repo (they can be cleaned up later if they ever
show up).
Change-Id: If000163a321c869c46cfed4233c2ea42c3e8471b
Use '{{ zuul.pipeline }}' tag prefix in *-docker-image instead of
'change_{{ zuul.change }}' one when zuul.change is not provided, that is
the case with periodic jobs. This allows to build, upload and promote images
using periodic jobs e.g:
- project:
periodic:
- project-buildset-registry
- project-build-image1:
dependencies:
- name: project-buildset-registry
- project-build-image2:
dependencies:
- name: project-buildset-registry
# pulls from buildset registry and tests both images
- project-test:
dependencies:
- name: project-build-image1
- name: project-build-image2
# pre-pulls images from buildset registry for fast build
- project-upload-image1:
dependencies:
- name: project-test
- project-upload-image2:
dependencies:
- name: project-test
- project-promote:
dependencies:
- name: project-upload-image1
- name: project-upload-image2
This fuctionality will allow to keep latest images up to date for the
case when image incorporates continuously updating code from multiple
repositories.
Using true ternary for tag evaluation because ternary filter requires
all passed to it variables be defined or defaulted [0].
[0] https://github.com/ansible/ansible/issues/51276
Change-Id: I8eb7d2baa24905e7aac51fce0b2f9b1f24f037f9
Signed-off-by: Andrii Ostapenko <andrii.ostapenko@att.com>
A multi-arch manifist is a manifest list which has a different content-type
than a regular manifest. In order to re-tag the image correctly, tell
docker hub that we can accept both kinds of manifests, and re-upload
the one that it gives us. This will be a manifest list if it exists, or
a regular manifest if it doesn't.
Change-Id: I7863b0c824c0b3cb20f94ba67399e823a216092b
Adds yamllint to the linters with a minimal configuration, some
rules are disabled to allow us to fix them in follow-ups, if
we agree on them.
Fixes invalid YAML file containing characters inside block.
Fixes few minor linting issues.
Change-Id: I936fe2c997597972d884c5fc62655d28e8aaf8c5
The variable was changed inside the role from image to zj_image but the
included task file did not use the new variable name. This patch fixes
this.
Change-Id: Ibe3acbd0881da24ec9c2f636d777885a309bdf98
The missing "." from the content-type headers was causing us
to downgrade image manifests from v1 to to v2 when promoting them.
That can cause problems since many tools no longer support v1
manifests.
Notably, the docker registry is one of them.
Change-Id: I35a5d29933669b80b49578587ebe6db8e13e62ad
So that users can specify two docker image builds for the same
repository, but with different tags, ensure that the temporary
change_ tag attached to the image also includes the final tag
name.
This allows this configuration to work:
docker_images:
- repository: foo/image
context: opensuse
tags:
- opensuse-latest
- repository: foo/image
context: ubuntu
tags:
- ubuntu-latest
Change-Id: I917dcf8a74fc864ea06dc70bdb3e212dc170eb48