[stable/external-dns] Update psp apiVersion to 'policy/v1beta1' - Mandatory for K8s 1.16 (#17288)

* [stable/external-dns] Update psp apiVersion to 'policy/v1beta1' - Mandatory for K8s 1.16

Signed-off-by: juan131 <juan@bitnami.com>

* Update prerequisites

Signed-off-by: juan131 <juan@bitnami.com>

* Add a macro to decide the ApiVersion to use for PSP based on K8s API

Signed-off-by: juan131 <juan@bitnami.com>

* Fix chart version

Signed-off-by: juan131 <juan@bitnami.com>
This commit is contained in:
Juan Ariza Toledano
2019-09-20 08:41:42 -07:00
committed by Kubernetes Prow Robot
parent 1009ccbf71
commit 04558452f6
3 changed files with 13 additions and 2 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
apiVersion: v1
name: external-dns
version: 2.6.3
version: 2.6.4
appVersion: 0.5.17
description: ExternalDNS is a Kubernetes addon that configures public DNS servers with information about exposed Kubernetes services to make them discoverable.
keywords:
@@ -206,6 +206,17 @@ external-dns: infoblox.wapiPassword
{{- end -}}
{{- end -}}
{{/*
Return the appropriate apiVersion for PodSecurityPolicy.
*/}}
{{- define "podSecurityPolicy.apiVersion" -}}
{{- if semverCompare ">=1.14-0" .Capabilities.KubeVersion.GitVersion -}}
{{- print "policy/v1beta1" -}}
{{- else -}}
{{- print "extensions/v1beta1" -}}
{{- end -}}
{{- end -}}
{{/*
Validate values of External DNS:
- must provide the PowerDNS API URL when provider is "pdns"
+1 -1
View File
@@ -1,5 +1,5 @@
{{- if .Values.rbac.pspEnabled }}
apiVersion: extensions/v1beta1
apiVersion: {{ template "podSecurityPolicy.apiVersion" . }}
kind: PodSecurityPolicy
metadata:
name: {{ template "external-dns.fullname" . }}