[kube-prometheus-stack] Make namespace selector operator configurable - #5742
Merged
Conversation
This change adds the ability to configure the namespace selector operator in Prometheus rules. Users can now choose between including namespaces with the "=~" operator (default) or excluding namespaces with the "!~" operator. The new configuration option "appNamespacesOperator" in values.yaml allows users to specify which operator to use with the existing "appNamespacesTarget" pattern, making it possible to exclude specific namespaces from monitoring rules instead of only being able to include them. This is particularly useful for large clusters where you want to monitor everything except a few specific namespaces. Signed-off-by: Raul Garcia Sanchez <raul.garcia@meinauto.de>
rgarcia89
marked this pull request as ready for review
June 5, 2025 13:13
rgarcia89
requested review from
GMartinez-Sisti,
QuentinBisson,
Xtigyro,
andrewgkew,
gianrubio,
gkarthiks,
jkroepke and
scottrigby
as code owners
June 5, 2025 13:13
Signed-off-by: Raul Garcia Sanchez <raul.garcia@meinauto.de>
Contributor
Author
|
nevermind - I just saw the comment on the first line of the rules 😄 |
Member
|
@rgarcia89 such "special" changes are still possible, if you integrate them here: |
Contributor
Author
|
Understood. Let me have a look |
added 2 commits
June 5, 2025 15:54
Signed-off-by: Raul Garcia Sanchez <raul.garcia@meinauto.de>
Signed-off-by: Raul Garcia Sanchez <raul.garcia@meinauto.de>
Contributor
Author
|
@jkroepke do you have a clue why the test is failing? |
Member
Bad luck |
|
Just to give Kudos. I tried to do that like 4 weeks ago via using a negative look ahead which of course did not work. Thank you so much ❤️ ❤️ ❤️ |
This was referenced Aug 23, 2025
Closed
Closed
Closed
This was referenced Aug 24, 2025
feat(container)!: Update image kube-prometheus-stack to v77 - autoclosed
ismailbay/k8s-dev-stack#422
Closed
feat(container)!: Update image kube-prometheus-stack to v77 - autoclosed
martinjonsson01/cluster#672
Closed
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This change adds the ability to configure the namespace selector operator
in Prometheus rules. Users can now choose between including namespaces with
the
=~operator (default) or excluding namespaces with the!~operator.The new configuration option "appNamespacesOperator" in values.yaml allows
users to specify which operator to use with the existing "appNamespacesTarget"
pattern, making it possible to exclude specific namespaces from monitoring
rules instead of only being able to include them.
This is particularly useful for large clusters where you want to monitor
everything except a few specific namespaces.
Signed-off-by: Raul Garcia Sanchez raul.garcia@meinauto.de
What this PR does / why we need it
Which issue this PR fixes
(optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)format, will close that issue when PR gets merged)Special notes for your reviewer
Checklist
[prometheus-couchdb-exporter])