We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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 Operator 0.73.0, too many warnings for "'bearerTokenFile' is deprecated, use 'authorization' instead." see below
0.73.0
level=info ts=2024-04-10T00:11:25.626328388Z caller=main.go:186 msg="Starting Prometheus Operator" version="(version=0.73.0, branch=, revision=unknown)" level=info ts=2024-04-10T00:11:25.626384961Z caller=main.go:187 build_context="(go=go1.22.2, platform=linux/amd64, user=, date=20240404-09:17:29, tags=unknown)" level=info ts=2024-04-10T00:11:25.626394609Z caller=main.go:198 msg="namespaces filtering configuration " config="{allow_list=\"\",deny_list=\"\",prometheus_allow_list=\"\",alertmanager_allow_list=\"\",alertmanagerconfig_allow_list=\"\",thanosruler_allow_list=\"\"}" level=info ts=2024-04-10T00:11:25.63146596Z caller=main.go:227 msg="connection established" cluster-version=v1.24.17 level=info ts=2024-04-10T00:11:25.663438527Z caller=operator.go:335 component=prometheus-controller msg="Kubernetes API capabilities" endpointslices=true level=info ts=2024-04-10T00:11:25.679068736Z caller=operator.go:320 component=prometheusagent-controller msg="Kubernetes API capabilities" endpointslices=true level=info ts=2024-04-10T00:11:25.712511639Z caller=server.go:298 msg="starting insecure server" address=[::]:8080 level=info ts=2024-04-10T00:11:26.356414111Z caller=operator.go:429 component=prometheusagent-controller msg="successfully synced all caches" level=info ts=2024-04-10T00:11:26.357127012Z caller=operator.go:313 component=alertmanager-controller msg="successfully synced all caches" level=info ts=2024-04-10T00:11:26.357175525Z caller=operator.go:283 component=thanos-controller msg="successfully synced all caches" level=warn ts=2024-04-10T00:11:26.595531046Z caller=promcfg.go:1374 component=prometheus-controller msg="'bearerTokenFile' is deprecated, use 'authorization' instead." version=v2.51.1 service_monitor=monitoring/dev-c2-kube-prometheus-apiserver level=warn ts=2024-04-10T00:11:26.595572632Z caller=promcfg.go:1374 component=prometheus-controller msg="'bearerTokenFile' is deprecated, use 'authorization' instead." version=v2.51.1 service_monitor=monitoring/dev-c2-kube-prometheus-coredns level=warn ts=2024-04-10T00:11:26.595592351Z caller=promcfg.go:1374 component=prometheus-controller msg="'bearerTokenFile' is deprecated, use 'authorization' instead." version=v2.51.1 service_monitor=monitoring/dev-c2-kube-prometheus-kube-controller-manager level=warn ts=2024-04-10T00:11:26.595609821Z caller=promcfg.go:1374 component=prometheus-controller msg="'bearerTokenFile' is deprecated, use 'authorization' instead." version=v2.51.1 service_monitor=monitoring/dev-c2-kube-prometheus-kube-proxy level=warn ts=2024-04-10T00:11:26.595626565Z caller=promcfg.go:1374 component=prometheus-controller msg="'bearerTokenFile' is deprecated, use 'authorization' instead." version=v2.51.1 service_monitor=monitoring/dev-c2-kube-prometheus-kube-scheduler level=warn ts=2024-04-10T00:11:26.59567254Z caller=promcfg.go:1374 component=prometheus-controller msg="'bearerTokenFile' is deprecated, use 'authorization' instead." version=v2.51.1 service_monitor=monitoring/dev-c2-kube-prometheus-kubelet (repeatedly)
example servicemonitor with bearerTokenFile that causes warinings in prometheus operator
apiVersion: monitoring.coreos.com/v1 kind: ServiceMonitor ... spec: endpoints: - bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token ...
no warnings or just warnings once
too many warnings for "'bearerTokenFile' is deprecated, use 'authorization' instead."
1.24.17
Other (please comment): K8S
Other (please comment): Helm Chart bitnami/kube-prometheus
No response
level=warn ts=2024-04-10T00:11:26.595531046Z caller=promcfg.go:1374 component=prometheus-controller msg="'bearerTokenFile' is deprecated, use 'authorization' instead." version=v2.51.1 service_monitor=monitoring/dev-c2-kube-prometheus-apiserver
The text was updated successfully, but these errors were encountered:
Technically not a bug this is showing in logs since more context added in log here https://github.com/prometheus-operator/prometheus-operator/pull/6410/files#diff-453ce9c721c51bf9591c2b212e9ce50157b9c40d1b211177bf502be268099656R1352 since a deprecated field
A fix would be to use the new scrapeClasses feature from Prometheus CRD which would automatically inject the authorization credentials
scrapeClasses
may be a documentation for scrapeClass would be good
cc: @nicolastakashi @simonpasquier
Sorry, something went wrong.
My feeling is that the logs are too aggressive indeed. I'll propose a patch and we can cut a 0.73.1 release after it.
This is fixed and patch release done 0.73.1
0.73.1
No branches or pull requests
Is there an existing issue for this?
What happened?
Description
Prometheus Operator
0.73.0
, too many warnings for "'bearerTokenFile' is deprecated, use 'authorization' instead." see belowexample servicemonitor with bearerTokenFile that causes warinings in prometheus operator
Steps to Reproduce
Expected Result
no warnings or just warnings once
Actual Result
too many warnings for "'bearerTokenFile' is deprecated, use 'authorization' instead."
Prometheus Operator Version
Kubernetes Version
1.24.17
Kubernetes Cluster Type
Other (please comment): K8S
How did you deploy Prometheus-Operator?
Other (please comment): Helm Chart bitnami/kube-prometheus
Manifests
No response
prometheus-operator log output
level=warn ts=2024-04-10T00:11:26.595531046Z caller=promcfg.go:1374 component=prometheus-controller msg="'bearerTokenFile' is deprecated, use 'authorization' instead." version=v2.51.1 service_monitor=monitoring/dev-c2-kube-prometheus-apiserver
Anything else?
No response
The text was updated successfully, but these errors were encountered: