newrelic / helm-charts

Helm charts for New Relic applications
Apache License 2.0
95 stars 201 forks source link

[newrelic-logging] Adding more than one podLabel results in invalid yaml errors #1373

Open Chris-Pohl opened 1 month ago

Chris-Pohl commented 1 month ago

We are trying to add multiple labels to the logging pods but we are getting invalid yaml errors. If we add 0 or 1 labels it works fine.

This is the label section being generated when attempting to do multiple labels:

      labels:
        app: newrelic-logging
        release: logging
        kubernetes.io/os: linux
        app.kubernetes.io/name: newrelic-logging
        customKey1: customValue1
customKey2: customValue2
customKey3: customValue3
customKey4: customValue4
customKey5: customValue5
customKey6: customValue6

We think this line in the helm chart needs to have an "| nindent 8 }}" section added to the end like other elements in the yaml. https://github.com/newrelic/helm-charts/blob/master/charts/newrelic-logging/templates/daemonset.yaml#L32

When we tested adding "| indent 8 }}" it still errored and this was the generated yaml output:

      labels:
        app: newrelic-logging
        release: logging
        kubernetes.io/os: linux
        app.kubernetes.io/name: newrelic-logging
                customKey1: customValue1
        customKey2: customValue2
        customKey3: customValue3
        customKey4: customValue4
        customKey5: customValue5
        customKey6: customValue6

When we tested adding "| nindent 8 }}" it worked and this was the generated yaml output:

      labels:
        app: newrelic-logging
        release: logging
        kubernetes.io/os: linux
        app.kubernetes.io/name: newrelic-logging

        customKey1: customValue1
        customKey2: customValue2
        customKey3: customValue3
        customKey4: customValue4
        customKey5: customValue5
        customKey6: customValue6
workato-integration[bot] commented 1 month ago

https://new-relic.atlassian.net/browse/NR-272135