From 4ef91a27019f17529207e7b9a447ade10d5acfd7 Mon Sep 17 00:00:00 2001 From: "M. Mert Yildiran" Date: Tue, 27 Jun 2023 03:27:40 +0300 Subject: [PATCH] :sparkles: Template the `controller` field in `IngressClass` resource --- config/configStructs/tapConfig.go | 1 + helm-chart/templates/10-ingress-class.yaml | 2 +- helm-chart/values.yaml | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/config/configStructs/tapConfig.go b/config/configStructs/tapConfig.go index ff0373d91..e1cdf4e55 100644 --- a/config/configStructs/tapConfig.go +++ b/config/configStructs/tapConfig.go @@ -87,6 +87,7 @@ type AuthConfig struct { type IngressConfig struct { Enabled bool `yaml:"enabled" json:"enabled" default:"false"` ClassName string `yaml:"className" json:"className" default:"kubeshark-ingress-class"` + Controller string `yaml:"controller" json:"controller" default:"k8s.io/ingress-nginx"` Host string `yaml:"host" json:"host" default:"ks.svc.cluster.local"` TLS []networking.IngressTLS `yaml:"tls" json:"tls"` Auth AuthConfig `yaml:"auth" json:"auth"` diff --git a/helm-chart/templates/10-ingress-class.yaml b/helm-chart/templates/10-ingress-class.yaml index c1f511980..34dd9ccf8 100644 --- a/helm-chart/templates/10-ingress-class.yaml +++ b/helm-chart/templates/10-ingress-class.yaml @@ -11,5 +11,5 @@ metadata: name: kubeshark-ingress-class namespace: {{ .Values.tap.selfnamespace }} spec: - controller: k8s.io/ingress-nginx + controller: {{ .Values.tap.ingress.controller }} {{- end }} diff --git a/helm-chart/values.yaml b/helm-chart/values.yaml index cc4363a98..dcbe932d1 100644 --- a/helm-chart/values.yaml +++ b/helm-chart/values.yaml @@ -46,6 +46,7 @@ tap: ingress: enabled: false className: kubeshark-ingress-class + controller: k8s.io/ingress-nginx host: ks.svc.cluster.local tls: [] auth: