Unverified Commit 23a99f48 authored by Joshua Powers's avatar Joshua Powers Committed by GitHub

fix: sync telegraf-ds to properly format output subtables (#505)

fixes: #498
parent 14a3212f
apiVersion: v1 apiVersion: v1
name: telegraf-ds name: telegraf-ds
version: 1.1.1 version: 1.1.2
appVersion: 1.23.3 appVersion: 1.23.3
deprecated: false deprecated: false
description: Telegraf is an agent written in Go for collecting, processing, aggregating, and writing metrics. description: Telegraf is an agent written in Go for collecting, processing, aggregating, and writing metrics.
......
...@@ -133,7 +133,7 @@ app.kubernetes.io/instance: {{ .Release.Name }} ...@@ -133,7 +133,7 @@ app.kubernetes.io/instance: {{ .Release.Name }}
{{- range $key, $value := $config -}} {{- range $key, $value := $config -}}
{{- $tp := typeOf $value -}} {{- $tp := typeOf $value -}}
{{- if eq $tp "map[string]interface {}" }} {{- if eq $tp "map[string]interface {}" }}
[[outputs.{{ $output }}.{{ $key }}]] [outputs.{{ $output }}.{{ $key }}]
{{- range $k, $v := $value }} {{- range $k, $v := $value }}
{{- $tps := typeOf $v }} {{- $tps := typeOf $v }}
{{- if eq $tps "string" }} {{- if eq $tps "string" }}
...@@ -163,7 +163,7 @@ app.kubernetes.io/instance: {{ .Release.Name }} ...@@ -163,7 +163,7 @@ app.kubernetes.io/instance: {{ .Release.Name }}
] ]
{{- end }} {{- end }}
{{- if eq $tps "map[string]interface {}"}} {{- if eq $tps "map[string]interface {}"}}
[[outputs.{{ $output }}.{{ $key }}.{{ $k }}]] [outputs.{{ $output }}.{{ $key }}.{{ $k }}]
{{- range $foo, $bar := $v }} {{- range $foo, $bar := $v }}
{{ $foo }} = {{ $bar | quote }} {{ $foo }} = {{ $bar | quote }}
{{- end }} {{- end }}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment