diff --git a/charts/nutanix-csi-storage/templates/ntnx-secret.yaml b/charts/nutanix-csi-storage/templates/ntnx-secret.yaml index b76bb9e..a6c8388 100644 --- a/charts/nutanix-csi-storage/templates/ntnx-secret.yaml +++ b/charts/nutanix-csi-storage/templates/ntnx-secret.yaml @@ -1,5 +1,6 @@ -{{- if eq .Values.createSecret true }} {{- if eq .Values.kindtest false }} +{{- if eq .Values.createSecret true }} + {{- $username := .Values.username | required "username is required to create secret." -}} {{- $password := .Values.password | required "password is required to create secret." -}} @@ -15,7 +16,6 @@ data: # E.g.: echo -n "10.83.0.91:9440:admin:mypassword" | base64 key: {{ printf "%s:9440:%s:%s" .Values.prismEndPoint .Values.username .Values.password | b64enc}} {{- end }} -{{- end }} {{- if eq .Values.createPrismCentralSecret true }} @@ -33,3 +33,4 @@ data: # E.g.: echo -n "10.83.0.91:9440:admin:mypassword" | base64 key: {{ printf "%s:9440:%s:%s" .Values.prismCentralEndPoint .Values.pcUsername .Values.pcPassword | b64enc}} {{- end }} +{{- end }} \ No newline at end of file