{{- if and (not .Values.rabbitmq.rabbitmq.existingErlangSecret) (not .Values.rabbitmq.rabbitmq.existingPasswordSecret) }}
apiVersion: v1
kind: Secret
metadata:
  name: {{ include "pipelines.fullname" . }}-rabbitmq-secret
  labels:
    {{- include "pipelines.labels" . | nindent 4 }}
type: Opaque
data:
  rabbitmq-erlang-cookie: {{ .Values.rabbitmq.rabbitmq.erlangCookie | b64enc | quote }}
  rabbitmq-password: {{ .Values.rabbitmq.rabbitmq.password | b64enc | quote }}
{{- end }}
