Update _ingressclass.tpl

This commit is contained in:
Kjeld Schouten-Lebbing 2022-02-12 16:41:18 +01:00 committed by GitHub
parent 0ebfe5244e
commit de4f3d66f9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -1,6 +1,7 @@
{{/* Define the ingressClass */}}
{{- define "traefik.ingressClass" -}}
{{- if .Values.ingressClass.enabled }}
---
{{ if .Values.ingressClass.enabled }}
{{- if .Capabilities.APIVersions.Has "networking.k8s.io/v1/IngressClass" }}
apiVersion: networking.k8s.io/v1
{{- else if .Capabilities.APIVersions.Has "networking.k8s.io/v1beta1/IngressClass" }}
@ -10,7 +11,6 @@ apiVersion: {{ printf "networking.k8s.io/%s" .Values.ingressClass.fallbackApiVer
{{- else }}
{{- fail "\n\n ERROR: You must have at least networking.k8s.io/v1beta1 to use ingressClass" }}
{{- end }}
---
kind: IngressClass
metadata:
annotations: