Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release adjustments and documentation #834

Merged
merged 3 commits into from
Aug 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 2 additions & 7 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,6 @@ on:
description: Kuadrant Operator replaced version
default: 0.0.0-alpha
type: string
channels:
description: Bundle and catalog channels, comma separated
default: preview
type: string
prerelease:
description: Is the release a pre-release?
required: false
Expand Down Expand Up @@ -68,14 +64,13 @@ jobs:
LIMITADOR_OPERATOR_VERSION=${{ inputs.limitadorOperatorVersion }} \
DNS_OPERATOR_VERSION=${{ inputs.dnsOperatorVersion }} \
WASM_SHIM_VERSION=${{ inputs.wasmShimVersion }} \
REPLACES_VERSION=${{ inputs.replacesVersion }} \
CHANNELS=${{ inputs.channels }}
REPLACES_VERSION=${{ inputs.replacesVersion }}
make prepare-release
- name: Commit and push
run: |
git config --global user.name "github-actions[bot]"
git config --global user.email "github-actions[bot]@users.noreply.github.com"
git add -A && git commit -m "Prepared release v${{ inputs.kuadrantOperatorVersion }}"
git add -A && git commit -m -s "Prepared release v${{ inputs.kuadrantOperatorVersion }}"
git push origin release-v${{ inputs.kuadrantOperatorVersion }}
- name: Create release
uses: softprops/action-gh-release@v1
Expand Down
3 changes: 1 addition & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -417,8 +417,7 @@ prepare-release: ## Prepare the manifests for OLM and Helm Chart for a release.
LIMITADOR_OPERATOR_VERSION=$(LIMITADOR_OPERATOR_VERSION) \
DNS_OPERATOR_VERSION=$(DNS_OPERATOR_VERSION) \
WASM_SHIM_VERSION=$(WASM_SHIM_VERSION) \
REPLACES_VERSION=$(REPLACES_VERSION) \
CHANNELS=$(CHANNELS)
REPLACES_VERSION=$(REPLACES_VERSION)
$(MAKE) helm-build VERSION=$(VERSION) \
AUTHORINO_OPERATOR_VERSION=$(AUTHORINO_OPERATOR_VERSION) \
LIMITADOR_OPERATOR_VERSION=$(LIMITADOR_OPERATOR_VERSION) \
Expand Down
51 changes: 51 additions & 0 deletions RELEASE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# How to release Kuadrant Operator

## Process

To release a version _“v0.W.Z”_ of Kuadrant Operator in GitHub and Quay.io, follow these steps:

1. Kuadrant dependencies need to be released first:
* [Authorino Operator](https://github.com/Kuadrant/authorino-operator/blob/main/RELEASE.md).
* [Limitador Operator](https://github.com/Kuadrant/limitador-operator/blob/main/RELEASE.md).
* [DNS Operator](https://github.com/Kuadrant/dns-operator/blob/main/docs/RELEASE.md).
* [WASM Shim](https://github.com/Kuadrant/wasm-shim/).

2. Run the GHA [Release operator](https://github.com/Kuadrant/kuadrant-operator/actions/workflows/release.yaml); make
sure to fill all the fields:

* Branch containing the release workflow file – default: `main`
* Commit SHA or branch name of the operator to release – usually: `main`
* Operator version to release (without prefix) – i.e. `0.W.Z`
* Kuadrant dependencies (WASM Shim, Authorino, Limitador and DNS operators) versions (without prefix) – i.e. `0.X.Y`
* Operator replaced version (without prefix) – i.e. `0.P.Q`
* If the release is a prerelease

3. Run the GHA [Build and push images](https://github.com/Kuadrant/kuadrant-operator/actions/workflows/build-images-base.yaml)
specifying ‘Kuadrant operator version’ and its dependencies equals to the previously released versions _“0.X.Y”_. This will cause the
new images (bundle and catalog included) to be built and pushed to the corresponding repos in
[quay.io/kuadrant](https://quay.io/organization/kuadrant).


### Publishing the Operator in OpenShift Community Operators
Open a PR in the [OpenShift Community Operators repo](http://github.com/redhat-openshift-ecosystem/community-operators-prod)
([example](https://github.com/redhat-openshift-ecosystem/community-operators-prod/pull/1595) |
[docs](https://redhat-openshift-ecosystem.github.io/community-operators-prod/operator-release-process/)).

The usual steps are:

1. Start a new branch named `kuadrant-operator-v0.W.Z`

2. Create a new directory `operators/kuadrant-operator/0.W.Z` containing:

* Copy the bundle files from `github.com/kuadrant/kuadrant-operator/tree/v0.W.Z/bundle`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

openshift release requires some bits we do not have in this repo:

in metadata/annotations.yaml, the target catalog version

com.redhat.openshift.versions: "v4.12"

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

also, replaces field in the CSV is not needed.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd say let's shoot another PR to fix the OpertaorHub/OpenShift operators publishing, since it's not needed until GA. WDYT?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

also, it will need to be changed all along the dependencies

* Copy `github.com/kuadrant/kuadrant-operator/tree/v0.W.Z/bundle.Dockerfile` with the proper fix to the COPY commands
(i.e. remove /bundle from the paths)

### Publishing the Operator in Kubernetes Community Operators (OperatorHub.io)

1. Open a PR in the [Kubernetes Community Operators repo](https://github.com/k8s-operatorhub/community-operators)
([example](https://github.com/k8s-operatorhub/community-operators/pull/1655) | [docs](https://operatorhub.io/contribute)).

2. The usual steps are the same as for the
[OpenShift Community Operators](https://docs.google.com/document/d/1tLveyv8Zwe0wKyfUTWOlEnFeMB5aVGqIVDUjVYWax0U/edit#heading=h.b5tapxn4sbk5)
hub.
Loading