diff --git a/charts/mercure/templates/pdb.yaml b/charts/mercure/templates/pdb.yaml new file mode 100644 index 00000000..d216f207 --- /dev/null +++ b/charts/mercure/templates/pdb.yaml @@ -0,0 +1,13 @@ +{{- if or (and .Values.autoscaling.enabled (gt (.Values.autoscaling.minReplicas | int) 1)) (and (not .Values.autoscaling.enabled) (gt (.Values.replicaCount | int) 1)) }} +apiVersion: policy/v1 +kind: PodDisruptionBudget +metadata: + name: {{ include "mercure.fullname" . }} + labels: + {{- include "mercure.labels" . | nindent 4 }} +spec: + maxUnavailable: 1 + selector: + matchLabels: + {{- include "mercure.selectorLabels" . | nindent 6 }} +{{- end }}