From aa5b9ca34d8b270be947dc8ce94a0f124040a431 Mon Sep 17 00:00:00 2001 From: David Hurta Date: Thu, 25 Sep 2025 17:26:51 +0200 Subject: [PATCH] test: Include compressed tests binary in CVO container image To make the binary discoverable to the outside world. The following step is to register the binary in the origin repository to make the origin machine aware of the CVO tests extension. --- Dockerfile | 4 +++- Dockerfile.rhel | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 68427a5d5..f2c136810 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,10 +3,12 @@ WORKDIR /go/src/github.com/openshift/cluster-version-operator COPY . . RUN hack/build-go.sh; \ mkdir -p /tmp/build; \ - cp _output/linux/$(go env GOARCH)/cluster-version-operator /tmp/build/cluster-version-operator + cp _output/linux/$(go env GOARCH)/cluster-version-operator /tmp/build/cluster-version-operator; \ + cp _output/linux/$(go env GOARCH)/cluster-version-operator-tests.gz /tmp/build/cluster-version-operator-tests.gz FROM registry.access.redhat.com/ubi9/ubi-minimal:latest COPY --from=builder /tmp/build/cluster-version-operator /usr/bin/ +COPY --from=builder /tmp/build/cluster-version-operator-tests.gz /usr/bin/ COPY install /manifests COPY vendor/github.com/openshift/api/config/v1/zz_generated.crd-manifests/0000_00_cluster-version-operator_* /manifests/ COPY vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.crd-manifests/0000_00_cluster-version-operator_* /manifests/ diff --git a/Dockerfile.rhel b/Dockerfile.rhel index bd6fdb841..84dfc6aa3 100644 --- a/Dockerfile.rhel +++ b/Dockerfile.rhel @@ -3,10 +3,12 @@ WORKDIR /go/src/github.com/openshift/cluster-version-operator COPY . . RUN hack/build-go.sh; \ mkdir -p /tmp/build; \ - cp _output/linux/$(go env GOARCH)/cluster-version-operator /tmp/build/cluster-version-operator + cp _output/linux/$(go env GOARCH)/cluster-version-operator /tmp/build/cluster-version-operator; \ + cp _output/linux/$(go env GOARCH)/cluster-version-operator-tests.gz /tmp/build/cluster-version-operator-tests.gz FROM registry.ci.openshift.org/ocp/4.20:base-rhel9 COPY --from=builder /tmp/build/cluster-version-operator /usr/bin/ +COPY --from=builder /tmp/build/cluster-version-operator-tests.gz /usr/bin/ COPY install /manifests COPY vendor/github.com/openshift/api/config/v1/zz_generated.crd-manifests/0000_00_cluster-version-operator_* /manifests/ COPY vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.crd-manifests/0000_00_cluster-version-operator_* /manifests/