-
Notifications
You must be signed in to change notification settings - Fork 21
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
Fix bugs in release workflow #161
Fix bugs in release workflow #161
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #161 +/- ##
=======================================
Coverage 61.63% 61.63%
=======================================
Files 2 2
Lines 782 782
=======================================
Hits 482 482
Misses 249 249
Partials 51 51
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Makefile
Outdated
@@ -312,7 +312,7 @@ verify-manifests: manifests $(YQ) ## Verify manifests update. | |||
yq e -e '.metadata.annotations.containerImage == "$(OPERATOR_IMAGE)"' config/manifests/bases/authorino-operator.clusterserviceversion.yaml | |||
|
|||
.PHONY: verify-bundle | |||
verify-bundle: bundle $(YQ) ## Verify bundle update. | |||
verify-bundle: $(YQ) ## Verify bundle update. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This virtually makes running make verify-bundle
locally almost completely useless, but that's OK. In the end, locally, one can always run make bundle
and thus ensure that the manifests are correct and up to date. Because, otherwise, they have to be committed and included with the changes.
verify-bundle
only checks if the latest committed bundle manifests need update, by re-running make bundle
and checking if that leaves any unstaged diff. Perhaps this makes more sense in remote than to simply check locally if you didn't forget running make bundle
before pushing your changes.
So let's make this target indicated for usage by the automated workflows only and not so much by devs locally.
729abf1
to
c54b427
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks great, @adam-cattermole! Thank you so much!
I've left a couple minor suggestions.
f670453
to
453554e
Compare
453554e
to
ded5c1f
Compare
ded5c1f
to
caa7b65
Compare
Verification stepsVerify for latestGenerate the manifests: make bundle VERSION=$(git rev-parse HEAD) IMAGE_TAG=$(git rev-parse HEAD) Verify the manifests: make verify-manifests verify-bundle VERSION=$(git rev-parse HEAD) IMAGE_TAG=$(git rev-parse HEAD) Cleanup: git reset --hard Verify for a releasePrepare the release: make prepare-release VERSION=0.10.0 AUTHORINO_VERSION=0.16.0 CHANNELS=stable DEFAULT_CHANNEL=stable Check the manifests are correct: git diff diff --git a/bundle.Dockerfile b/bundle.Dockerfile
index 8fe9a64b..289359d2 100644
--- a/bundle.Dockerfile
+++ b/bundle.Dockerfile
@@ -5,7 +5,8 @@ LABEL operators.operatorframework.io.bundle.mediatype.v1=registry+v1
LABEL operators.operatorframework.io.bundle.manifests.v1=manifests/
LABEL operators.operatorframework.io.bundle.metadata.v1=metadata/
LABEL operators.operatorframework.io.bundle.package.v1=authorino-operator
-LABEL operators.operatorframework.io.bundle.channels.v1=alpha
+LABEL operators.operatorframework.io.bundle.channels.v1=stable
+LABEL operators.operatorframework.io.bundle.channel.default.v1=stable
LABEL operators.operatorframework.io.metrics.builder=operator-sdk-v1.22.0
LABEL operators.operatorframework.io.metrics.mediatype.v1=metrics+v1
LABEL operators.operatorframework.io.metrics.project_layout=go.kubebuilder.io/v3
diff --git a/bundle/manifests/authorino-operator.clusterserviceversion.yaml b/bundle/manifests/authorino-operator.clusterserviceversion.yaml
index d8cf8f64..e5db89e1 100644
--- a/bundle/manifests/authorino-operator.clusterserviceversion.yaml
+++ b/bundle/manifests/authorino-operator.clusterserviceversion.yaml
@@ -26,13 +26,13 @@ metadata:
]
capabilities: Basic Install
categories: Integration & Delivery
- containerImage: quay.io/kuadrant/authorino-operator:latest
+ containerImage: quay.io/kuadrant/authorino-operator:v0.10.0
createdAt: 2021-12-08T10-00-00Z
operators.operatorframework.io/builder: operator-sdk-v1.22.0
operators.operatorframework.io/project_layout: go.kubebuilder.io/v3
repository: https://github.com/Kuadrant/authorino-operator
support: kuadrant
- name: authorino-operator.v0.0.0
+ name: authorino-operator.v0.10.0
namespace: placeholder
spec:
apiservicedefinitions: {}
@@ -256,7 +256,7 @@ spec:
- --leader-elect
command:
- /manager
- image: quay.io/kuadrant/authorino-operator:latest
+ image: quay.io/kuadrant/authorino-operator:v0.10.0
livenessProbe:
httpGet:
path: /healthz
@@ -303,7 +303,7 @@ spec:
- command:
- authorino
- webhooks
- image: quay.io/kuadrant/authorino:latest
+ image: quay.io/kuadrant/authorino:v0.16.0
name: webhooks
ports:
- containerPort: 9443
@@ -429,7 +429,7 @@ spec:
minKubeVersion: 1.8.0
provider:
name: Red Hat
- version: 0.0.0
+ version: 0.10.0
webhookdefinitions:
- admissionReviewVersions:
- v1beta1
@@ -443,3 +443,4 @@ spec:
targetPort: 9443
type: ConversionWebhook
webhookPath: /convert
+ replaces: authorino-operator.v0.9.0
diff --git a/bundle/metadata/annotations.yaml b/bundle/metadata/annotations.yaml
index 118a56d0..e8e53507 100644
--- a/bundle/metadata/annotations.yaml
+++ b/bundle/metadata/annotations.yaml
@@ -4,7 +4,8 @@ annotations:
operators.operatorframework.io.bundle.manifests.v1: manifests/
operators.operatorframework.io.bundle.metadata.v1: metadata/
operators.operatorframework.io.bundle.package.v1: authorino-operator
- operators.operatorframework.io.bundle.channels.v1: alpha
+ operators.operatorframework.io.bundle.channels.v1: stable
+ operators.operatorframework.io.bundle.channel.default.v1: stable
operators.operatorframework.io.metrics.builder: operator-sdk-v1.22.0
operators.operatorframework.io.metrics.mediatype.v1: metrics+v1
operators.operatorframework.io.metrics.project_layout: go.kubebuilder.io/v3
diff --git a/config/authorino/kustomization.yaml b/config/authorino/kustomization.yaml
index ef0ddde0..31af44ab 100644
--- a/config/authorino/kustomization.yaml
+++ b/config/authorino/kustomization.yaml
@@ -2,14 +2,14 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
-- github.com/Kuadrant/authorino/install?ref=main
+- github.com/Kuadrant/authorino/install?ref=v0.16.0
- webhook
# Configures the conversion webhook
images:
- name: AUTHORINO_IMAGE
newName: quay.io/kuadrant/authorino
- newTag: latest
+ newTag: v0.16.0
patchesStrategicMerge:
- webhook/patches/webhook_in_authconfigs.yaml
diff --git a/config/deploy/manifests.yaml b/config/deploy/manifests.yaml
index 9c262bba..a7f28948 100644
--- a/config/deploy/manifests.yaml
+++ b/config/deploy/manifests.yaml
@@ -6150,7 +6150,7 @@ spec:
- --leader-elect
command:
- /manager
- image: quay.io/kuadrant/authorino-operator:latest
+ image: quay.io/kuadrant/authorino-operator:v0.10.0
livenessProbe:
httpGet:
path: /healthz
@@ -6201,7 +6201,7 @@ spec:
- command:
- authorino
- webhooks
- image: quay.io/kuadrant/authorino:latest
+ image: quay.io/kuadrant/authorino:v0.16.0
name: webhooks
ports:
- containerPort: 9443
diff --git a/config/manifests/bases/authorino-operator.clusterserviceversion.yaml b/config/manifests/bases/authorino-operator.clusterserviceversion.yaml
index 595b71ad..455682df 100644
--- a/config/manifests/bases/authorino-operator.clusterserviceversion.yaml
+++ b/config/manifests/bases/authorino-operator.clusterserviceversion.yaml
@@ -5,13 +5,13 @@ metadata:
alm-examples: '[]'
capabilities: Basic Install
categories: Integration & Delivery
- containerImage: quay.io/kuadrant/authorino-operator:latest
+ containerImage: quay.io/kuadrant/authorino-operator:v0.10.0
createdAt: 2021-12-08T10-00-00Z
operators.operatorframework.io/builder: operator-sdk-v1.9.0
operators.operatorframework.io/project_layout: unknown
repository: https://github.com/Kuadrant/authorino-operator
support: kuadrant
- name: authorino-operator.v0.0.0
+ name: authorino-operator.v0.10.0
namespace: placeholder
spec:
apiservicedefinitions: {}
@@ -67,4 +67,4 @@ spec:
minKubeVersion: 1.8.0
provider:
name: Red Hat
- version: 0.0.0
+ version: 0.10.0 Commit the changes as if you were simulating the creation of the release branch: git checkout -b simulation-v0.10.0
git add -Av
git commit -m "Simulate release v0.10.0" Verify the manifests: make verify-manifests VERSION=0.10.0 AUTHORINO_VERSION=0.16.0 CHANNELS=stable DEFAULT_CHANNEL=stable
Verify the bundle manifests: make verify-bundle VERSION=0.10.0 AUTHORINO_VERSION=0.16.0 CHANNELS=stable DEFAULT_CHANNEL=stable
|
34b789b
to
8f9f420
Compare
3859c55
to
6bb5d32
Compare
b7403e3
to
86d9333
Compare
86d9333
to
a022b2c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Excellent job, @adam-cattermole! Thank you!
No description provided.