blob: 7121fdcf74202ce2b7fd752b17a04ecad5bd10bd [file] [log] [blame]
{{/*
# Copyright 2020-present Open Networking Foundation
# SPDX-License-Identifier: LicenseRef-ONF-Member-Only-1.0
*/}}
{{- if .Values.image.credential }}
---
kind: Secret
apiVersion: v1
metadata:
name: "{{ .Values.image.credential.secretName }}"
labels:
release: {{ .Release.Name }}
type: kubernetes.io/dockerconfigjson
data:
.dockerconfigjson: {{ printf `{"auths":{%s:{"auth":"%s"}}}` (.Values.image.credential.registry | quote) (printf "%s:%s" .Values.image.credential.username .Values.image.credential.password | b64enc) | b64enc | quote }}
{{- end }}