Skip to content

Commit 8eadb99

Browse files
authored
Add missing annotation for OpenShift (#2562)
* Add missing annotation for OpenShift #2557 Signed-off-by: Israel Blancas <[email protected]> * Fix autogeneration Signed-off-by: Israel Blancas <[email protected]> * Add changelog Signed-off-by: Israel Blancas <[email protected]> * Apply changes requested in code review Signed-off-by: Israel Blancas <[email protected]> --------- Signed-off-by: Israel Blancas <[email protected]>
1 parent e75c6d0 commit 8eadb99

6 files changed

+43
-10
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
2+
change_type: bug_fix
3+
4+
# The name of the component, or a single word describing the area of concern, (e.g. operator, target allocator, github action)
5+
component: operator
6+
7+
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
8+
note: Fix annotations required by the OpenShift Operator Hub
9+
10+
# One or more tracking issues related to the change
11+
issues: [2557]
12+
13+
# (Optional) One or more lines of additional information to render under the primary note.
14+
# These lines will be padded with 2 spaces and then inserted directly into the document.
15+
# Use pipe (|) for multiline entries.
16+
subtext:

Makefile

+2-1
Original file line numberDiff line numberDiff line change
@@ -454,8 +454,9 @@ operator-sdk:
454454
bundle: kustomize operator-sdk manifests set-image-controller api-docs
455455
$(OPERATOR_SDK) generate kustomize manifests -q
456456
$(KUSTOMIZE) build config/manifests | $(OPERATOR_SDK) generate bundle -q --overwrite --version $(VERSION) $(BUNDLE_METADATA_OPTS)
457-
$(OPERATOR_SDK) bundle validate ./bundle
458457
./hack/ignore-createdAt-bundle.sh
458+
./hack/add-openshift-annotations.sh
459+
$(OPERATOR_SDK) bundle validate ./bundle
459460

460461
.PHONY: reset
461462
reset: kustomize operator-sdk manifests

RELEASE.md

+10-9
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,18 @@ Steps to release a new version of the OpenTelemetry Operator:
44

55
1. Change the `versions.txt`, so that it lists the target version of the OpenTelemetry Collector (operand), and the desired version for the target allocator and the operator. The `major.minor` should typically match, with the patch portion being possibly different.
66
2. Change the `autoinstrumentation-*` versions in `versions.txt` as per the latest supported versions in `autoinstrumentation/`.
7-
- :warning: DO NOT BUMP JAVA PAST `1.32.X` AND DO NOT BUMP .NET PAST `1.2.0`. :warning: Upgrades past these versions will introduce breaking HTTP semantic convention changes.
8-
3. Run `make bundle DOCKER_USER=open-telemetry VERSION=0.38.0`, using the version that will be released.
9-
4. Change the compatibility matrix in the [readme](./README.md) file, using the OpenTelemetry Operator version to be released and the current latest Kubernetes version as the latest supported version. Remove the oldest entry.
10-
5. Add the changes to the changelog. Manually add versions of all operator components.
11-
6. Check the OpenTelemetry Collector's changelog and ensure migration steps are present in `pkg/collector/upgrade`
12-
7. Once the changes above are merged and available in `main`, tag it with the desired version, prefixed with `v`: `v0.38.0`
13-
8. The GitHub Workflow will take it from here, creating a GitHub release with the generated artifacts (manifests) and publishing the images
14-
9. The GitHub Workflow, submits two pull requests to the Operator hub repositories. Make sure the pull requests are approved and merged.
7+
- :warning: DO NOT BUMP JAVA PAST `1.32.X` AND DO NOT BUMP .NET PAST `1.2.0`. :warning: Upgrades past these versions will introduce breaking HTTP semantic convention changes.
8+
3. Check if the compatible OpenShift versions are updated in the `hack/add-openshift-annotations.sh` script.
9+
4. Run `make bundle DOCKER_USER=open-telemetry VERSION=0.38.0`, using the version that will be released.
10+
5. Change the compatibility matrix in the [readme](./README.md) file, using the OpenTelemetry Operator version to be released and the current latest Kubernetes version as the latest supported version. Remove the oldest entry.
11+
6. Add the changes to the changelog. Manually add versions of all operator components.
12+
7. Check the OpenTelemetry Collector's changelog and ensure migration steps are present in `pkg/collector/upgrade`
13+
8. Once the changes above are merged and available in `main`, tag it with the desired version, prefixed with `v`: `v0.38.0`
14+
9. The GitHub Workflow will take it from here, creating a GitHub release with the generated artifacts (manifests) and publishing the images
15+
10. The GitHub Workflow, submits two pull requests to the Operator hub repositories. Make sure the pull requests are approved and merged.
1516
1. `community-operators-prod` is used by OLM on OpenShift. Example: [`operator-framework/community-operators-prod`](https://github.com/redhat-openshift-ecosystem/community-operators-prod/pull/494)
1617
1. `community-operators` is used by Operatorhub.io. Example: [`operator-framework/community-operators`](https://github.com/k8s-operatorhub/community-operators/pull/461)
17-
10. Update release schedule table, by moving the current release manager to the end of the table with updated release version.
18+
11. Update release schedule table, by moving the current release manager to the end of the table with updated release version.
1819

1920
## Generating the changelog
2021

bundle.Dockerfile

+1
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,4 @@ LABEL operators.operatorframework.io.test.config.v1=tests/scorecard/
1818
COPY bundle/manifests /manifests/
1919
COPY bundle/metadata /metadata/
2020
COPY bundle/tests/scorecard /tests/scorecard/
21+
LABEL com.redhat.openshift.versions="v4.11-v4.15"

bundle/metadata/annotations.yaml

+3
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,6 @@ annotations:
1212
# Annotations for testing.
1313
operators.operatorframework.io.test.mediatype.v1: scorecard+v1
1414
operators.operatorframework.io.test.config.v1: tests/scorecard/
15+
16+
# OpenShift specific annotations
17+
com.redhat.openshift.versions: "v4.11-v4.15"

hack/add-openshift-annotations.sh

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
#!/bin/bash
2+
3+
OPENSHIFT_VERSIONS="\"v4.11-v4.15\""
4+
5+
{
6+
echo ""
7+
echo " # OpenShift specific annotations"
8+
echo " com.redhat.openshift.versions: $OPENSHIFT_VERSIONS"
9+
} >> bundle/metadata/annotations.yaml
10+
11+
echo "LABEL com.redhat.openshift.versions=$OPENSHIFT_VERSIONS" >> bundle.Dockerfile

0 commit comments

Comments
 (0)