# PodDisruptionBudget to prevent degrading the server cluster through # voluntary cluster changes. {{ template "vault.mode" . }} {{- if and (and (eq (.Values.global.enabled | toString) "true") (eq .mode "ha")) (eq (.Values.server.ha.disruptionBudget.enabled | toString) "true") -}} apiVersion: policy/v1beta1 kind: PodDisruptionBudget metadata: name: {{ template "vault.fullname" . }} labels: app: {{ template "vault.name" . }} chart: {{ template "vault.chart" . }} heritage: {{ .Release.Service }} release: {{ .Release.Name }} spec: maxUnavailable: {{ template "vault.pdb.maxUnavailable" . }} selector: matchLabels: app: {{ template "vault.name" . }} release: "{{ .Release.Name }}" component: server {{- end -}}