diff --git a/charts/wave/templates/poddisruptionbudget.yaml b/charts/wave/templates/poddisruptionbudget.yaml new file mode 100644 index 00000000..204bcc10 --- /dev/null +++ b/charts/wave/templates/poddisruptionbudget.yaml @@ -0,0 +1,12 @@ +{{- if .Values.pdb.enabled }} +apiVersion: policy/v1 +kind: PodDisruptionBudget +metadata: + name: {{ include "wave-fullname" . }} + namespace: {{ .Release.Namespace }} +spec: + selector: + matchLabels: + {{ include "wave.selectorLabels" . | nindent 6}} + maxUnavailable: 1 +{{- end }} \ No newline at end of file diff --git a/charts/wave/values.yaml b/charts/wave/values.yaml index 9fcf2047..add081da 100644 --- a/charts/wave/values.yaml +++ b/charts/wave/values.yaml @@ -20,6 +20,10 @@ nodeSelector: {} # Replicas > 1 will enable leader election replicas: 1 +# Add PodDisruptionBudget which should be enabled for replicas > 1 +pdb: + enabled: false + # Additional volumes to use in the pod. extraVolumes: [] # - name: tmp