Publish container images to quay.io
Change-Id: If4b7596efd873acb8f06fddf016d9aff689b85ca
This commit is contained in:
parent
036e3adc73
commit
40764b6e7a
74
.zuul.yaml
74
.zuul.yaml
@ -1,24 +1,36 @@
|
|||||||
# Image building jobs
|
# Image building jobs
|
||||||
- secret:
|
- secret:
|
||||||
name: zuul-registry-dockerhub
|
name: zuul-registry-registry-credentials
|
||||||
data:
|
data:
|
||||||
username: zuulzuul
|
quay.io:
|
||||||
password: !encrypted/pkcs1-oaep
|
username: zuul-ci+opendevzuul
|
||||||
- mc+bK6/dQJ/gzrR5jFYEm9eepVfWG0xiTxxPCunDN0tgbis+xbe1cBOAEdZmjkNrXO/0V
|
password: !encrypted/pkcs1-oaep
|
||||||
6d7EcH0JP8mD9jgaTMVWKhVHUF4m/pikP5S4oKgfQYf9PKtzaSp298fhu+4RzuKR01ywj
|
- U8grF8lgA4UYRsuELWGXo5WtqRrhDbq5JbFds743nNaRgih/INwociBXwpF1mNxiQLOv3
|
||||||
ks8MWj2oZKJeikQVVbK6z8wMQYirxmaUvivKOU6eJmiPMYs3AaC+P6oc1vEGHMFaa+QpG
|
PIh/QzSaGEe1sYpNL2awT9G6BL1X2ViqtlQn7aW1EoNjtjg1ZnXHwMlFk1ByU4UWG+m7K
|
||||||
3hD2z+y7Ix/YFKyDQPk4DOs1lTveE18RCBIiP4IRXuYxKkR5uSqj4KEmdcdxBZ6mQyTbw
|
pNmV9JcthnHPafAEb+423mrJKM1N1/XG+y6EMujsEnXaHq4oxCbegWJJa6cv7heAWSbuf
|
||||||
uZwLMPlkFTNYkaKetobVMo79I3HEACPRN7ylhu96690DsJ7QkvEQD6LPqw82XODuM+T4o
|
UcFh2SmQu/r0eCIpqES5CtthvUQ62sQxAULDe4QRic1kJRDQiuP0HsReEPebT/bjaR2RY
|
||||||
u9kJLLhPhZEALGE9yga4RC6YxfWx1KbJRr74vu5ctxTffuDQGwHjYYf76B0TPuX72UuaP
|
YEFKcHZnafvr7Sl42Yo8g3ETqb30H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4OKN8cMUYvRMjH2Zfy1ioNySDG91qUMhzy3yGyakAfZZBruK02wvws
|
||||||
|
/4PJgCGC55BNZ0phLzCrwsgWsalLOqrt+NzMwPwnecemJnDqT0o7EB8LjtPYzy1e8iA3U
|
||||||
|
dWJrwa1kWTZInB/Adv0CFS972zgygC0l0nRGnl3wje65w7h4CdxLwfT5FXsBtlE4PgWW2
|
||||||
|
zK7UIJk3c61loYKZSllwCi/046lPZWhFq31fYIrUwlPDRyTqI3WvE9ns3Ow5rzGdLGgN+
|
||||||
|
YrzUOdJFHC44rUDEgeRsMC4ssj6lqVzM5Gl3PRd8DfdLkYkg3NeDJqGtrTO8bnj+kv6Nl
|
||||||
|
KpMEnTeMw7AoFybtgvGaeajozvj+wlAsmel3RnVi8oioLrwi8GrVFzUshgxW80=
|
||||||
|
|
||||||
- job:
|
- job:
|
||||||
name: zuul-registry-build-image
|
name: zuul-registry-build-image
|
||||||
description: Build and test a Docker image.
|
description: Build and test a container image.
|
||||||
parent: opendev-build-docker-image
|
parent: opendev-build-container-image
|
||||||
allowed-projects: zuul/zuul-registry
|
allowed-projects: zuul/zuul-registry
|
||||||
run: playbooks/functional-test/run.yaml
|
run: playbooks/functional-test/run.yaml
|
||||||
post-run: playbooks/functional-test/post.yaml
|
post-run: playbooks/functional-test/post.yaml
|
||||||
@ -28,9 +40,13 @@
|
|||||||
provides: zuul-registry-container-image
|
provides: zuul-registry-container-image
|
||||||
nodeset: ubuntu-jammy
|
nodeset: ubuntu-jammy
|
||||||
vars: &image_vars
|
vars: &image_vars
|
||||||
docker_images:
|
promote_container_image_method: intermediate-registry
|
||||||
|
promote_container_image_job: zuul-registry-upload-image
|
||||||
|
container_command: docker
|
||||||
|
container_images:
|
||||||
- context: .
|
- context: .
|
||||||
repository: zuul/zuul-registry
|
registry: quay.io
|
||||||
|
repository: quay.io/zuul-ci/zuul-registry
|
||||||
target: zuul-registry
|
target: zuul-registry
|
||||||
tags:
|
tags:
|
||||||
# If zuul.tag is defined: [ '3', '3.19', '3.19.0' ]. Only works for 3-component tags.
|
# If zuul.tag is defined: [ '3', '3.19', '3.19.0' ]. Only works for 3-component tags.
|
||||||
@ -39,15 +55,15 @@
|
|||||||
|
|
||||||
- job:
|
- job:
|
||||||
name: zuul-registry-upload-image
|
name: zuul-registry-upload-image
|
||||||
parent: opendev-upload-docker-image
|
parent: opendev-upload-container-image
|
||||||
description: Build and test a Docker image and upload to Docker Hub.
|
description: Build and test a container image.
|
||||||
allowed-projects: zuul/zuul-registry
|
allowed-projects: zuul/zuul-registry
|
||||||
run: playbooks/functional-test/run.yaml
|
run: playbooks/functional-test/run.yaml
|
||||||
post-run: playbooks/functional-test/post.yaml
|
post-run: playbooks/functional-test/post.yaml
|
||||||
nodeset: ubuntu-jammy
|
nodeset: ubuntu-jammy
|
||||||
secrets:
|
secrets:
|
||||||
name: docker_credentials
|
name: container_registry_credentials
|
||||||
secret: zuul-registry-dockerhub
|
secret: zuul-registry-registry-credentials
|
||||||
pass-to-parent: true
|
pass-to-parent: true
|
||||||
requires:
|
requires:
|
||||||
- python-builder-3.10-bullseye-container-image
|
- python-builder-3.10-bullseye-container-image
|
||||||
@ -57,12 +73,12 @@
|
|||||||
|
|
||||||
- job:
|
- job:
|
||||||
name: zuul-registry-promote-image
|
name: zuul-registry-promote-image
|
||||||
parent: opendev-promote-docker-image
|
parent: opendev-promote-container-image
|
||||||
description: Promote previously uploaded Docker image.
|
description: Promote previously uploaded container image.
|
||||||
allowed-projects: zuul/zuul-registry
|
allowed-projects: zuul/zuul-registry
|
||||||
secrets:
|
secrets:
|
||||||
name: docker_credentials
|
name: container_registry_credentials
|
||||||
secret: zuul-registry-dockerhub
|
secret: zuul-registry-registry-credentials
|
||||||
pass-to-parent: true
|
pass-to-parent: true
|
||||||
nodeset:
|
nodeset:
|
||||||
nodes: []
|
nodes: []
|
||||||
@ -96,11 +112,11 @@
|
|||||||
release:
|
release:
|
||||||
jobs:
|
jobs:
|
||||||
- opendev-release-python
|
- opendev-release-python
|
||||||
- upload-docker-image:
|
- upload-container-image:
|
||||||
secrets:
|
secrets:
|
||||||
name: docker_credentials
|
name: container_registry_credentials
|
||||||
secret: zuul-registry-dockerhub
|
secret: zuul-registry-registry-credentials
|
||||||
pass-to-parent: true
|
pass-to-parent: true
|
||||||
vars:
|
vars:
|
||||||
<<: *image_vars
|
<<: *image_vars
|
||||||
upload_docker_image_promote: false
|
upload_container_image_promote: false
|
||||||
|
@ -4,7 +4,7 @@ version: '2'
|
|||||||
|
|
||||||
services:
|
services:
|
||||||
registry:
|
registry:
|
||||||
image: zuul/zuul-registry
|
image: quay.io/zuul-ci/zuul-registry
|
||||||
volumes:
|
volumes:
|
||||||
- "./conf/:/conf/:z"
|
- "./conf/:/conf/:z"
|
||||||
- "/tmp/registry-test/tls/:/tls:z"
|
- "/tmp/registry-test/tls/:/tls:z"
|
||||||
|
@ -4,7 +4,7 @@ version: '2'
|
|||||||
|
|
||||||
services:
|
services:
|
||||||
registry:
|
registry:
|
||||||
image: zuul/zuul-registry
|
image: quay.io/zuul-ci/zuul-registry
|
||||||
volumes:
|
volumes:
|
||||||
- "./conf/:/conf/:z"
|
- "./conf/:/conf/:z"
|
||||||
- "/tmp/registry-test/tls/:/tls:z"
|
- "/tmp/registry-test/tls/:/tls:z"
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
# This installs docker and runs a buildset registry
|
# This installs docker and runs a buildset registry
|
||||||
- hosts: all
|
- hosts: all
|
||||||
roles:
|
roles:
|
||||||
- build-docker-image
|
- build-container-image
|
||||||
|
|
||||||
- hosts: all
|
- hosts: all
|
||||||
name: Set up for tests
|
name: Set up for tests
|
||||||
@ -30,9 +30,9 @@
|
|||||||
include_tasks: setup.yaml
|
include_tasks: setup.yaml
|
||||||
|
|
||||||
- hosts: all
|
- hosts: all
|
||||||
name: Run docker standard registry test
|
name: Run container standard registry test
|
||||||
tasks:
|
tasks:
|
||||||
- name: Run docker test tasks
|
- name: Run container test tasks
|
||||||
include_tasks: docker.yaml
|
include_tasks: docker.yaml
|
||||||
|
|
||||||
- hosts: all
|
- hosts: all
|
||||||
|
@ -61,7 +61,7 @@
|
|||||||
command: "cp /run/user/{{ ansible_user_uid }}/auth.json {{ workspace }}/containers-auth.json"
|
command: "cp /run/user/{{ ansible_user_uid }}/auth.json {{ workspace }}/containers-auth.json"
|
||||||
|
|
||||||
- name: Create a local containers image
|
- name: Create a local containers image
|
||||||
shell: buildah commit --rm $(buildah from docker.io/zuul/zuul-registry) testimage
|
shell: buildah commit --rm $(buildah from quay.io/zuul-ci/zuul-registry) testimage
|
||||||
|
|
||||||
- name: Ensure image file is not present
|
- name: Ensure image file is not present
|
||||||
file:
|
file:
|
||||||
|
Loading…
Reference in New Issue
Block a user