mirror of
https://github.com/helm/charts.git
synced 2026-08-23 22:37:45 +00:00
Conditional cadvisor metrics for kubelet serviceMonitor (#21653)
Signed-off-by: Valentin Zayash <valioozz@gmail.com>
This commit is contained in:
@@ -12,7 +12,7 @@ sources:
|
||||
- https://github.com/coreos/kube-prometheus
|
||||
- https://github.com/coreos/prometheus-operator
|
||||
- https://coreos.com/operators/prometheus
|
||||
version: 8.12.6
|
||||
version: 8.12.7
|
||||
appVersion: 0.37.0
|
||||
tillerVersion: ">=2.12.0"
|
||||
home: https://github.com/coreos/prometheus-operator
|
||||
|
||||
@@ -524,6 +524,7 @@ For a full list of configurable values please refer to the [Grafana chart](https
|
||||
| `kubeStateMetrics.serviceMonitor.relabelings` | The `relabel_configs` for scraping `kube-state-metrics`. | `` |
|
||||
| `kubelet.enabled` | Deploy servicemonitor to scrape the kubelet service. See also `prometheusOperator.kubeletService` | `true` |
|
||||
| `kubelet.namespace` | Namespace where the kubelet is deployed. See also `prometheusOperator.kubeletService.namespace` | `kube-system` |
|
||||
| `kubelet.serviceMonitor.cAdvisor` | Enable scraping `/metrics/cadvisor` from kubelet's service | `true` |
|
||||
| `kubelet.serviceMonitor.cAdvisorMetricRelabelings` | The `metric_relabel_configs` for scraping cAdvisor. | `` |
|
||||
| `kubelet.serviceMonitor.cAdvisorRelabelings` | The `relabel_configs` for scraping cAdvisor. | `[{"sourceLabels":["__metrics_path__"], "targetLabel":"metrics_path"}]` |
|
||||
| `kubelet.serviceMonitor.https` | Enable scraping of the kubelet over HTTPS. For more information, see https://github.com/coreos/prometheus-operator/issues/926 | `true` |
|
||||
|
||||
@@ -28,6 +28,7 @@ spec:
|
||||
relabelings:
|
||||
{{ toYaml .Values.kubelet.serviceMonitor.relabelings | indent 4 }}
|
||||
{{- end }}
|
||||
{{- if .Values.kubelet.serviceMonitor.cAdvisor }}
|
||||
- port: https-metrics
|
||||
scheme: https
|
||||
path: /metrics/cadvisor
|
||||
@@ -46,6 +47,7 @@ spec:
|
||||
{{- if .Values.kubelet.serviceMonitor.cAdvisorRelabelings }}
|
||||
relabelings:
|
||||
{{ toYaml .Values.kubelet.serviceMonitor.cAdvisorRelabelings | indent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- else }}
|
||||
- port: http-metrics
|
||||
@@ -61,6 +63,7 @@ spec:
|
||||
relabelings:
|
||||
{{ toYaml .Values.kubelet.serviceMonitor.relabelings | indent 4 }}
|
||||
{{- end }}
|
||||
{{- if .Values.kubelet.serviceMonitor.cAdvisor }}
|
||||
- port: http-metrics
|
||||
path: /metrics/cadvisor
|
||||
{{- if .Values.kubelet.serviceMonitor.interval }}
|
||||
@@ -74,6 +77,7 @@ spec:
|
||||
{{- if .Values.kubelet.serviceMonitor.cAdvisorRelabelings }}
|
||||
relabelings:
|
||||
{{ toYaml .Values.kubelet.serviceMonitor.cAdvisorRelabelings | indent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
jobLabel: k8s-app
|
||||
|
||||
@@ -566,6 +566,10 @@ kubelet:
|
||||
##
|
||||
https: true
|
||||
|
||||
## Enable scraping /metrics/cadvisor from kubelet's service
|
||||
##
|
||||
cAdvisor: true
|
||||
|
||||
## Metric relabellings to apply to samples before ingestion
|
||||
##
|
||||
cAdvisorMetricRelabelings: []
|
||||
|
||||
Reference in New Issue
Block a user