Skip to content

Commit e6b123f

Browse files
committed
Revert "feat: rhcos os-version change no longer requires an annotation for OCP catalog bundle"
This reverts commit 836e965. Signed-off-by: Fred Rolland <[email protected]>
1 parent 53dc682 commit e6b123f

File tree

3 files changed

+5
-1
lines changed

3 files changed

+5
-1
lines changed

Makefile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ IMAGE_NAME?=network-operator
5050
CONTROLLER_IMAGE=$(REGISTRY)/$(IMAGE_NAME)
5151
IMAGE_BUILD_OPTS?=
5252
BUNDLE_IMG?=network-operator-bundle:$(VERSION)
53+
BUNDLE_OCP_VERSIONS?=v4.15-v4.18
5354
# BUNDLE_GEN_FLAGS are the flags passed to the operator-sdk generate bundle command
5455
BUNDLE_GEN_FLAGS ?= -q --overwrite --version $(VERSION) $(BUNDLE_METADATA_OPTS)
5556
BUILD_ARCH= amd64 arm64
@@ -406,7 +407,7 @@ bundle: $(OPERATOR_SDK) $(KUSTOMIZE) manifests ## Generate bundle manifests and
406407
cd config/manager && $(KUSTOMIZE) edit set image controller=$(TAG)
407408
$(KUSTOMIZE) build config/manifests | $(OPERATOR_SDK) generate bundle $(BUNDLE_GEN_FLAGS)
408409
git checkout -- config/manager/kustomization.yaml
409-
GO=$(GO) TAG=$(TAG) hack/scripts/ocp-bundle-postprocess.sh
410+
GO=$(GO) BUNDLE_OCP_VERSIONS=$(BUNDLE_OCP_VERSIONS) TAG=$(TAG) hack/scripts/ocp-bundle-postprocess.sh
410411
$(OPERATOR_SDK) bundle validate ./bundle
411412

412413
.PHONY: bundle-build

bundle/metadata/annotations.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,4 @@ annotations:
1313
# Annotations for testing.
1414
operators.operatorframework.io.test.mediatype.v1: scorecard+v1
1515
operators.operatorframework.io.test.config.v1: tests/scorecard/
16+
com.redhat.openshift.versions: v4.15-v4.18

hack/scripts/ocp-bundle-postprocess.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,3 +35,5 @@ rm hack/related_images.yaml
3535
# Escape the tag annotation value for sed
3636
ESCAPED_TAG=$(printf '%s\n' "$TAG" | sed -e 's/[]\/$*.^[]/\\&/g')
3737
sed -i "0,/annotations:/s/annotations:/annotations:\n containerImage: $ESCAPED_TAG/" bundle/manifests/nvidia-network-operator.clusterserviceversion.yaml
38+
# Add OpenShift versions in metadata/annotations.yaml
39+
echo " com.redhat.openshift.versions: $BUNDLE_OCP_VERSIONS" >> bundle/metadata/annotations.yaml

0 commit comments

Comments
 (0)