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

[prometheus-kube-stack] Unable to configure oauth2 for the default created alertmanager endpoint config. #5197

Open
d4rkfella opened this issue Jan 18, 2025 · 1 comment
Labels
bug Something isn't working

Comments

@d4rkfella
Copy link

d4rkfella commented Jan 18, 2025

Describe the bug a clear and concise description of what the bug is.

Hello, i've been banging my head for 2 hours straight and im unable to configure oauth for authenticating to alertmanager. The alertingEndpoints doesnt follow the official documentation and its really confusing . For example tlsConfig is translated to tls_config when the configuration file is rendered. These are some of the values i tried but none of them worked.

alertingEndpoints:
          - scheme: https
            name: alertmanager-operated
            port: 8081
            tlsConfig:
              serverName: <servername>
            oauth2:
              clientId:
                secret:
                  name:  prometheus-oauth2-credentials
                  key: client_id
              clientSecret:
                name: prometheus-oauth2-credentials
                key: client_secret
              tokenUrl: <token_url>
              scopes: ["openid", "profile", "email"]
              endpointParams:
                grant_type: client_credentials


alertingEndpoints:
          - scheme: https
            name: alertmanager-operated
            port: 8081
            tlsConfig:
              serverName: <servername>
            oauth2:
              client_id: <client_id>
              client_secret_file: /vault/secrets/client_secret
              token_url: <token_url>
              scopes: ["openid", "profile", "email"]
              endpoint_params:
                grant_type: client_credentials

What's your helm version?

v3.17.0

What's your kubectl version?

v1.32.0

Which chart?

kube-prometheus-stack

What's the chart version?

68.2.0

What happened?

No response

What you expected to happen?

No response

How to reproduce it?

No response

Enter the changed values of values.yaml?

No response

Enter the command that you execute and failing/misfunctioning.

.

Anything else we need to know?

No response

@d4rkfella d4rkfella added the bug Something isn't working label Jan 18, 2025
@d4rkfella
Copy link
Author

It seems the operator doesnt support the oauth2 option in the alertingEndpoints block, i used AdditionalAlertManagerConfigs to make it work, but can i disable the default endpoint that is created ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant