-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Feat: add validation for Alertmanager HTTPConfig in Global Config #7910
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
base: main
Are you sure you want to change the base?
Feat: add validation for Alertmanager HTTPConfig in Global Config #7910
Conversation
Thanks for the PR! Before implementing the validation of Alertmanager resources in the webhook service, I'd recommend that we address potential gaps that we have in the operator's logic. For instance the following Alertmanager resource would result in a crashlooping pod (provided that a apiVersion: monitoring.coreos.com/v1
kind: Alertmanager
metadata:
name: example
spec:
alertmanagerConfiguration:
global:
httpConfig:
authorization:
credentials:
key: bar
name: foo
bearerTokenSecret:
key: bar
name: foo
name: config-example
|
@simonpasquier I'll review it later today. |
@simonpasquier May I understand what is the expected result? If both are specified (authorization.credentials and bearerTokenSecret), which one should be the highest precedence? |
Description
This PR adds admission for the Alertmanager HTTPConfig in global configuration.
Type of change
What type of changes does your code introduce to the Prometheus operator? Put an
x
in the box that apply.CHANGE
(fix or feature that would cause existing functionality to not work as expected)FEATURE
(non-breaking change which adds functionality)BUGFIX
(non-breaking change which fixes an issue)ENHANCEMENT
(non-breaking change which improves existing functionality)NONE
(if none of the other choices apply. Example, tooling, build system, CI, docs, etc.)Verification
Please check the Prometheus-Operator testing guidelines for recommendations about automated tests.
Changelog entry
Please put a one-line changelog entry below. This will be copied to the changelog file during the release process.