Skip to content

Commit d5a7358

Browse files
authored
[FIX] Add PDB support to latest kubernetes versions (#759)
1 parent af32767 commit d5a7358

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

charts/apisix/templates/pdb.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,11 @@
1515
# limitations under the License.
1616

1717
{{- if (.Values.podDisruptionBudget.enabled) }}
18+
{{ if semverCompare "<1.21-0" .Capabilities.KubeVersion.Version -}}
1819
apiVersion: policy/v1beta1
20+
{{- else -}}
21+
apiVersion: policy/v1
22+
{{- end }}
1923
kind: PodDisruptionBudget
2024
metadata:
2125
name: {{ include "apisix.fullname" . }}

0 commit comments

Comments
 (0)