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 backwards incompatible change: include a prometheus service by default #6699
Conversation
…fault Signed-off-by: Tim Ramlot <42113979+inteon@users.noreply.github.com>
@@ -1,4 +1,4 @@ | |||
{{- if and .Values.prometheus.enabled .Values.prometheus.servicemonitor.enabled }} | |||
{{- if and .Values.prometheus.enabled (not .Values.prometheus.podmonitor.enabled) }} |
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.
I would have preferred making the simplest possible change, and returning it to be exactly how it used to be.
$ git diff origin/release-1.13 origin/release-1.14 -- deploy/charts/cert-
manager/templates/service.yaml
diff --git a/deploy/charts/cert-manager/templates/service.yaml b/deploy/charts/cert-manager/templates/service.yaml
index ec34d5878..112a55228 100644
--- a/deploy/charts/cert-manager/templates/service.yaml
+++ b/deploy/charts/cert-manager/templates/service.yaml
@@ -1,4 +1,4 @@
-{{- if .Values.prometheus.enabled }}
+{{- if and .Values.prometheus.enabled .Values.prometheus.servicemonitor.enabled }}
apiVersion: v1
kind: Service
metadata:
What harm does the Service resource do if the user also enables PodMonitor?
What if a user wants the metrics Service for some other bespoke monitoring system and they want to use the PodMonitor?
I guess this can easily be changed again in a future release.
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.
podmonitor
was added in this release.
I think best thing to do right now is to keep the current behavior without extending the behavior to the new options that we added.
Co-authored-by: Richard Wall <wallrj@users.noreply.github.com> Signed-off-by: Tim Ramlot <42113979+inteon@users.noreply.github.com>
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.
Ok. Thanks.
/lgtm
/approve
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.
/lgtm
/approve
(Looks like the labels from the previous review weren't picked up. Adding my own review to poke prow)
/cherry-pick release-1.14 |
@SgtCoDFish: once the present PR merges, I will cherry-pick it on top of release-1.14 in a new PR and assign it to you. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: SgtCoDFish, wallrj The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@SgtCoDFish: #6699 failed to apply on top of branch "release-1.14":
In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
I'll manually backport |
In #6459 the prometheus service was made conditional both on
.Values.prometheus.enabled
and.Values.prometheus.servicemonitor.enabled
. This however conflicts with the original intentions of the author of this Service: #1942 (comment).For that reason, we decided to still include the service when only
.Values.prometheus.enabled
is set.We do however remove the service when
.Values.prometheus.podmonitor.enabled
is true and aim to add an extra option in the future to disable this service.Kind
/kind bug
Release Note