{{ if and (eq .Values.jenkins.configuration.secretRefName "") (.Values.jenkins.configuration.secretData) }}
apiVersion: v1
kind: Secret
type: Opaque
metadata:
  name: jenkins-{{ .Values.jenkins.name }}
  namespace: {{ .Values.jenkins.namespace }}
{{- with .Values.jenkins.configuration.secretData }}
data: {{ toYaml . | nindent 2 }}
{{- end }}
{{ end }}
