Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 0 additions & 10 deletions chart/templates/_helpers.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -720,16 +720,6 @@ server_tls_key_file = /etc/pgbouncer/server.key
{{ $config | toJson | print }}
{{- end }}

{{/* Allow Kubernetes Version to be overridden. Credit to https://github.com/prometheus-community/helm-charts for Regex. */}}
{{- define "kubeVersion" }}
{{- $kubeVersion := default .Capabilities.KubeVersion.Version .Values.kubeVersionOverride -}}
{{/* Special use case for Amazon EKS, Google GKE */}}
{{- if and (regexMatch "\\d+\\.\\d+\\.\\d+-(?:eks|gke).+" $kubeVersion) (not .Values.kubeVersionOverride) -}}
{{- $kubeVersion = regexFind "\\d+\\.\\d+\\.\\d+" $kubeVersion -}}
{{- end -}}
{{- $kubeVersion -}}
{{- end }}

{{/*
Set the default value for pod securityContext
If no value is passed for securityContexts.pod or <node>.securityContexts.pod or legacy securityContext and <node>.securityContext, defaults to global uid and gid.
Expand Down
4 changes: 0 additions & 4 deletions chart/templates/cleanup/cleanup-cronjob.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,7 @@
{{- $tolerations := or .Values.cleanup.tolerations .Values.tolerations }}
{{- $topologySpreadConstraints := or .Values.cleanup.topologySpreadConstraints .Values.topologySpreadConstraints }}
{{- $securityContext := include "airflowPodSecurityContext" (list . .Values.cleanup) }}
{{- if semverCompare ">= 1.21.x" (include "kubeVersion" .) }}
apiVersion: batch/v1
{{- else }}
apiVersion: batch/v1beta1
{{- end }}
kind: CronJob
metadata:
name: {{ .Release.Name }}-cleanup
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,7 @@
#################################
{{- if and .Values.pgbouncer.enabled .Values.pgbouncer.podDisruptionBudget.enabled }}
kind: PodDisruptionBudget
{{- if semverCompare ">= 1.21.x" (include "kubeVersion" .) }}
apiVersion: policy/v1
{{- else }}
apiVersion: policy/v1beta1
{{- end }}
metadata:
name: {{ .Release.Name }}-pgbouncer-pdb
labels:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,7 @@
#################################
{{- if .Values.scheduler.podDisruptionBudget.enabled }}
kind: PodDisruptionBudget
{{- if semverCompare ">= 1.21.x" (include "kubeVersion" .) }}
apiVersion: policy/v1
{{- else }}
apiVersion: policy/v1beta1
{{- end }}
metadata:
name: {{ .Release.Name }}-scheduler-pdb
labels:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,7 @@
#################################
{{- if .Values.webserver.podDisruptionBudget.enabled }}
kind: PodDisruptionBudget
{{- if semverCompare ">= 1.21.x" (include "kubeVersion" .) }}
apiVersion: policy/v1
{{- else }}
apiVersion: policy/v1beta1
{{- end }}
metadata:
name: {{ .Release.Name }}-webserver-pdb
labels:
Expand Down
6 changes: 0 additions & 6 deletions chart/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,6 @@
"default": "",
"x-docsSection": null
},
"kubeVersionOverride": {
"description": "Provide a Kubernetes version (used for API Version selection) to override the auto-detected version",
"type": "string",
"default": "",
"x-docsSection": null
},
"uid": {
"description": "User of airflow user.",
"type": "integer",
Expand Down
3 changes: 0 additions & 3 deletions chart/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@ fullnameOverride: ""
# Provide a name to substitute for the name of the chart
nameOverride: ""

# Provide a Kubernetes version (used for API Version selection) to override the auto-detected version
kubeVersionOverride: ""

# Max number of old replicasets to retain. Can be overridden by each deployment's revisionHistoryLimit
revisionHistoryLimit: ~

Expand Down