mirror of https://github.com/apache/druid.git
helm: Fix PDB apiVersion to allow K8s 1.25+ deployment (#13783)
This commit is contained in:
parent
9ffaba9c7f
commit
355cdbeb86
|
@ -30,7 +30,7 @@ dependencies:
|
|||
version: 8.6.4
|
||||
repository: https://charts.helm.sh/stable
|
||||
condition: postgresql.enabled
|
||||
version: 0.3.3
|
||||
version: 0.3.4
|
||||
home: https://druid.apache.org/
|
||||
icon: https://druid.apache.org/img/favicon.png
|
||||
sources:
|
||||
|
|
|
@ -0,0 +1,17 @@
|
|||
{{/*
|
||||
Return the target Kubernetes version
|
||||
*/}}
|
||||
{{- define "capabilities.kubeVersion" -}}
|
||||
{{- default .Capabilities.KubeVersion.Version .Values.kubeVersion -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the appropriate apiVersion for poddisruptionbudget.
|
||||
*/}}
|
||||
{{- define "capabilities.policy.apiVersion" -}}
|
||||
{{- if semverCompare "<1.21-0" (include "capabilities.kubeVersion" .) -}}
|
||||
{{- print "policy/v1beta1" -}}
|
||||
{{- else -}}
|
||||
{{- print "policy/v1" -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
|
@ -18,7 +18,7 @@
|
|||
*/}}
|
||||
|
||||
{{- if .Values.historical.podDisruptionBudget.enabled }}
|
||||
apiVersion: policy/v1beta1
|
||||
apiVersion: {{ include "capabilities.policy.apiVersion" . }}
|
||||
kind: PodDisruptionBudget
|
||||
metadata:
|
||||
labels:
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
*/}}
|
||||
|
||||
{{- if .Values.middleManager.podDisruptionBudget.enabled }}
|
||||
apiVersion: policy/v1beta1
|
||||
apiVersion: {{ include "capabilities.policy.apiVersion" . }}
|
||||
kind: PodDisruptionBudget
|
||||
metadata:
|
||||
labels:
|
||||
|
|
Loading…
Reference in New Issue