{{- if .Values.replicaSet.enabled }}
apiVersion: policy/v1beta1
kind: PodDisruptionBudget
metadata:
  labels:
    app: {{ template "mongodb.name" . }}
    chart: {{ template "mongodb.chart" . }}
    heritage: {{ .Release.Service }}
    release: {{ .Release.Name }}
  name: {{ template "mongodb.fullname" . }}-arbiter
spec:
  selector:
    matchLabels:
      app: {{ template "mongodb.name" . }}
      release: {{ .Release.Name }}
      component: arbiter
  minAvailable: {{ .Values.replicaSet.pdb.minAvailable.arbiter }}
{{- end }}