Now manage kubernetes version in ingress

The backend and ingressClassName are now under condition
This commit is contained in:
2022-02-16 10:37:46 +01:00
parent 722c7424d0
commit a4834a0661
4 changed files with 55 additions and 13 deletions

View File

@@ -38,14 +38,16 @@ type IngressHttp struct {
type IngressPath struct {
Path string
PathType string `yaml:"pathType"`
Backend IngressBackend
Backend *IngressBackend
}
type IngressBackend struct {
Service IngressService
Service IngressService
ServiceName string `yaml:"serviceName"` // for kubernetes version < 1.18
ServicePort interface{} `yaml:"servicePort"` // for kubernetes version < 1.18
}
type IngressService struct {
Name string
Port map[string]interface{}
Name string `yaml:"name"`
Port map[string]interface{} `yaml:"port"`
}