Pārlūkot izejas kodu

Only set dnspolicy if explicitly specified

Waqar Ahmed 4 gadi atpakaļ
vecāks
revīzija
8b338dcb7d

+ 5 - 3
library/common/2105.0.0/templates/lib/networking/_dns.tpl

@@ -2,9 +2,11 @@
 DNS Configuration
 */}}
 {{- define "common.networking.dnsConfiguration" }}
+{{ if .Values.dnsPolicy }}
 dnsPolicy: {{ .Values.dnsPolicy }}
-{{- if .Values.dnsConfig }}
+{{ end }}
+{{ if .Values.dnsConfig }}
 dnsConfig:
-  {{- toYaml .Values.dnsConfig | nindent 2 }}
-{{- end }}
+  {{ toYaml .Values.dnsConfig | nindent 2 }}
+{{ end }}
 {{- end }}