File tree 4 files changed +23
-1
lines changed
4 files changed +23
-1
lines changed Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ dependencies:
25
25
# to the chart and its templates, including the app version.
26
26
# Versions are expected to follow Semantic Versioning (https://semver.org/)
27
27
28
- version : 5.0.4
28
+ version : 5.1.0
29
29
30
30
31
31
# This is the version number of the application being deployed. This version number should be
Original file line number Diff line number Diff line change @@ -397,6 +397,8 @@ If you don't want the sub charts to installed add the relevant flag per sub char
397
397
398
398
399
399
## Change log
400
+ * 5.1.0
401
+ - Respect metric filters in ` prometheus/kubelet ` scrape endpoint
400
402
* 5.0.4
401
403
- Add support for global tolerations
402
404
* 5.0.3
Original file line number Diff line number Diff line change @@ -92,6 +92,16 @@ Build config file for standalone OpenTelemetry Collector
92
92
{ {- $metricsApplications := dict " exporters" (list " prometheusremotewrite/applications" ) " processors" (list " attributes/env_id" " filter/kubernetes360" ) " receivers" (list " prometheus/applications" ) -} }
93
93
{ {- $_ := set .Values.metricsConfig.service.pipelines " metrics/applications" $metricsApplications -} }
94
94
{ {- end -} }
95
+
96
+ { {- range $job := (index $configData " receivers" " prometheus/kubelet" " config" " scrape_configs" ) -} }
97
+ { {- range $key ,$filter := ($infraFilters | fromJson) -} }
98
+ { {- if contains " metric" $key -} }
99
+ { {- $_ := set $job (" metric_relabel_configs" | toYaml) ( append $job .metric_relabel_configs ($filter )) -} }
100
+ { {- else -} }
101
+ { {- $_ := set $job (" relabel_configs" | toYaml) ( append $job .relabel_configs ($filter )) -} }
102
+ { {- end -} }
103
+ { {- end -} }
104
+ { {- end -} }
95
105
{ {- end -} }
96
106
{ {- .Values.standaloneCollector.configOverride | merge $configData | mustMergeOverwrite $config | toYaml} }
97
107
{ {- end -} }
@@ -251,6 +261,15 @@ Build config file for standalone OpenTelemetry Collector daemonset
251
261
{ {- $_ := set .Values.daemonsetConfig.service.pipelines " metrics/applications" $metricsApplications -} }
252
262
{ {- end -} }
253
263
264
+ { {- range $job := (index $configData " receivers" " prometheus/kubelet" " config" " scrape_configs" ) -} }
265
+ { {- range $key ,$filter := ($infraFilters | fromJson) -} }
266
+ { {- if contains " metric" $key -} }
267
+ { {- $_ := set $job (" metric_relabel_configs" | toYaml) ( append $job .metric_relabel_configs ($filter )) -} }
268
+ { {- else -} }
269
+ { {- $_ := set $job (" relabel_configs" | toYaml) ( append $job .relabel_configs ($filter )) -} }
270
+ { {- end -} }
271
+ { {- end -} }
272
+ { {- end -} }
254
273
{ {- end -} }
255
274
256
275
{ {- .Values.daemonsetCollector.configOverride | merge $configData | mustMergeOverwrite $config | toYaml} }
Original file line number Diff line number Diff line change @@ -1152,6 +1152,7 @@ daemonsetConfig:
1152
1152
selectors :
1153
1153
- field : metadata.name=$KUBE_NODE_NAME
1154
1154
role : node
1155
+ metric_relabel_configs : []
1155
1156
metrics_path : /metrics
1156
1157
relabel_configs :
1157
1158
- action : labelmap
You can’t perform that action at this time.
0 commit comments