From 0d2c91745bf68018b11b34030bb4727edf29aca6 Mon Sep 17 00:00:00 2001 From: Mohammed Naser Date: Wed, 11 Dec 2024 23:34:48 -0500 Subject: [PATCH] Stop using CDN for CI (#2185) Switch image builds to use Harbor Switch Zuul to avoid CDN Small more fixes Configure CI bits to not use CDN --- build/pin-images.py | 7 +++++-- images/barbican/Dockerfile | 4 ++-- images/cinder/Dockerfile | 4 ++-- images/designate/Dockerfile | 4 ++-- images/glance/Dockerfile | 4 ++-- images/heat/Dockerfile | 4 ++-- images/horizon/Dockerfile | 4 ++-- images/ironic/Dockerfile | 7 ++++++- images/keepalived/Dockerfile | 2 +- images/keystone/Dockerfile | 4 ++-- images/kubernetes-entrypoint/Dockerfile | 2 +- images/libvirtd/Dockerfile | 2 +- images/magnum/Dockerfile | 6 +++--- images/manila/Dockerfile | 4 ++-- images/netoffload/Dockerfile | 4 ++-- images/neutron/Dockerfile | 4 ++-- images/nova-ssh/Dockerfile | 2 +- images/nova/Dockerfile | 4 ++-- images/octavia/Dockerfile | 4 ++-- images/openstack-runtime/Dockerfile | 2 +- images/openstack-venv-builder/Dockerfile | 4 ++-- images/ovn/Dockerfile | 4 ++-- images/placement/Dockerfile | 4 ++-- images/python-base/Dockerfile | 2 +- images/python-openstackclient/Dockerfile | 4 ++-- images/staffeln/Dockerfile | 4 ++-- images/tempest/Dockerfile | 6 +++--- images/ubuntu-cloud-archive/Dockerfile | 2 +- images/ubuntu/Dockerfile | 2 +- molecule/csi/verify.yml | 2 +- zuul.d/container-images/barbican.yaml | 4 ++-- zuul.d/container-images/base.yaml | 2 +- zuul.d/container-images/cinder.yaml | 4 ++-- zuul.d/container-images/designate.yaml | 4 ++-- zuul.d/container-images/glance.yaml | 4 ++-- zuul.d/container-images/heat.yaml | 4 ++-- zuul.d/container-images/horizon.yaml | 4 ++-- zuul.d/container-images/ironic.yaml | 4 ++-- zuul.d/container-images/keepalived.yaml | 4 ++-- zuul.d/container-images/keystone.yaml | 4 ++-- zuul.d/container-images/kubernetes-entrypoint.yaml | 4 ++-- zuul.d/container-images/libvirtd.yaml | 4 ++-- zuul.d/container-images/magnum.yaml | 4 ++-- zuul.d/container-images/manila.yaml | 4 ++-- zuul.d/container-images/netoffload.yaml | 4 ++-- zuul.d/container-images/neutron.yaml | 4 ++-- zuul.d/container-images/nova-ssh.yaml | 4 ++-- zuul.d/container-images/nova.yaml | 4 ++-- zuul.d/container-images/octavia.yaml | 4 ++-- zuul.d/container-images/openstack-python-runtime.yaml | 6 +++--- zuul.d/container-images/openstack-runtime.yaml | 4 ++-- zuul.d/container-images/openstack-venv-builder.yaml | 4 ++-- zuul.d/container-images/openvswitch.yaml | 4 ++-- zuul.d/container-images/ovn.yaml | 8 ++++---- zuul.d/container-images/placement.yaml | 4 ++-- zuul.d/container-images/python-base.yaml | 4 ++-- zuul.d/container-images/python-openstackclient.yaml | 4 ++-- zuul.d/container-images/staffeln.yaml | 4 ++-- zuul.d/container-images/tempest.yaml | 4 ++-- zuul.d/container-images/ubuntu-cloud-archive.yaml | 4 ++-- zuul.d/container-images/ubuntu.yaml | 4 ++-- zuul.d/playbooks/common/switch-to-atmosphere-mirror.yml | 8 +++++++- zuul.d/secrets.yaml | 4 ++-- 63 files changed, 133 insertions(+), 119 deletions(-) diff --git a/build/pin-images.py b/build/pin-images.py index 1bf4112d0..f7485da6c 100755 --- a/build/pin-images.py +++ b/build/pin-images.py @@ -65,10 +65,13 @@ def get_digest(image_ref, token=None): def get_pinned_image(image_src): image_ref = reference.Reference.parse(image_src) - if image_ref.domain() == "registry.atmosphere.dev": + if ( + image_ref.domain() == "registry.atmosphere.dev" + or image_ref.domain() == "harbor.atmosphere.dev" + ): # Get token for docker.io r = requests.get( - "https://registry.atmosphere.dev/service/token", + "https://harbor.atmosphere.dev/service/token", timeout=5, params={ "service": "harbor-registry", diff --git a/images/barbican/Dockerfile b/images/barbican/Dockerfile index f457a0b48..89281275a 100644 --- a/images/barbican/Dockerfile +++ b/images/barbican/Dockerfile @@ -3,7 +3,7 @@ ARG RELEASE -FROM registry.atmosphere.dev/library/openstack-venv-builder:${RELEASE} AS build +FROM harbor.atmosphere.dev/library/openstack-venv-builder:${RELEASE} AS build ARG BARBICAN_GIT_REF=d99764e6112cedc6ca168a29fb0279dec2d94288 ADD --keep-git-dir=true https://opendev.org/openstack/barbican.git#${BARBICAN_GIT_REF} /src/barbican RUN git -C /src/barbican fetch --unshallow @@ -14,5 +14,5 @@ pip3 install \ pykmip EOF -FROM registry.atmosphere.dev/library/openstack-python-runtime:${RELEASE} +FROM harbor.atmosphere.dev/library/openstack-python-runtime:${RELEASE} COPY --from=build --link /var/lib/openstack /var/lib/openstack diff --git a/images/cinder/Dockerfile b/images/cinder/Dockerfile index f109f1972..425258f36 100644 --- a/images/cinder/Dockerfile +++ b/images/cinder/Dockerfile @@ -3,7 +3,7 @@ ARG RELEASE -FROM registry.atmosphere.dev/library/openstack-venv-builder:${RELEASE} AS build +FROM harbor.atmosphere.dev/library/openstack-venv-builder:${RELEASE} AS build ARG CINDER_GIT_REF=db98dc207060da234c32a563c13cac1edbd62952 ADD --keep-git-dir=true https://opendev.org/openstack/cinder.git#${CINDER_GIT_REF} /src/cinder RUN git -C /src/cinder fetch --unshallow @@ -19,7 +19,7 @@ pip3 install \ storpool.spopenstack EOF -FROM registry.atmosphere.dev/library/openstack-python-runtime:${RELEASE} +FROM harbor.atmosphere.dev/library/openstack-python-runtime:${RELEASE} RUN <>>>>>> 4ad7b51a (Stop using CDN for CI (#2185)) ADD --keep-git-dir=true https://opendev.org/openstack/ironic.git#${IRONIC_GIT_REF} /src/ironic RUN git -C /src/ironic fetch --unshallow RUN --mount=type=cache,mode=0755,target=/root/.cache/pip,sharing=private <