title: Helm can't iterate over range from set-file
body: <p>I want to loop over a secret file I'm generating in my ci pipeline.</p>
  
  <pre><code>helm template \
    ...
    --set-file secretmap="secretmap.yaml" \
    ...
  </code></pre>
  
  <p>The <code>secretmap.yaml</code> is generated and contains the following:</p>
  
  <pre><code>SEC_1: 111
  SEC_2: 222
  ...
  </code></pre>
  
  <p>The secret.yaml looks like this:</p>
  
  <pre><code>kind: Secret
  ...
  data:
  {{- range $key, $val := .Values.secretmap }}
    {{ $key }}: {{ $val | b64enc | quote }}
  {{- end }}
  ...
  </code></pre>
  
  <p>And the error I get is:</p>
  
  <pre><code>Error: render error in ".../secret.yaml": template: .../secret.yaml:4:31: ... range can't iterate over SEC_1: 111
  SEC_1: 222
  ...
  </code></pre>
  
  <p>The same configuration does work with configmap though,<br>
  where I set the configmap from <code>-f chart/values/common.yaml</code></p>