diff --git a/charts/cp-zookeeper/templates/poddisruptionbudget.yaml b/charts/cp-zookeeper/templates/poddisruptionbudget.yaml index bb5e1ad9..00e139c8 100644 --- a/charts/cp-zookeeper/templates/poddisruptionbudget.yaml +++ b/charts/cp-zookeeper/templates/poddisruptionbudget.yaml @@ -1,4 +1,8 @@ +{{- if semverCompare "<1.21.0-0" ( .Capabilities.KubeVersion.Version ) }} apiVersion: policy/v1beta1 +{{- else }} +apiVersion: policy/v1 +{{- end }} kind: PodDisruptionBudget metadata: name: {{ template "cp-zookeeper.fullname" . }}-pdb