should ignore ingress if the old ingress class annotation and the new are not equal to the expected by Ingress Controller
This commit is contained in:
parent
01c9a2bf25
commit
f9cffb2d62
1 changed files with 8 additions and 5 deletions
|
@ -466,11 +466,14 @@ func New(
|
|||
|
||||
var errOld, errCur error
|
||||
var classCur string
|
||||
if !icConfig.IgnoreIngressClass {
|
||||
_, errOld = store.GetIngressClass(oldIng, icConfig)
|
||||
classCur, errCur = store.GetIngressClass(curIng, icConfig)
|
||||
}
|
||||
if errOld != nil && errCur == nil {
|
||||
|
||||
_, errOld = store.GetIngressClass(oldIng, icConfig)
|
||||
classCur, errCur = store.GetIngressClass(curIng, icConfig)
|
||||
|
||||
if errCur != nil && errOld != nil {
|
||||
klog.InfoS("Ignoring ingress because of error while validating ingress class", "ingress", klog.KObj(curIng), "error", errCur)
|
||||
return
|
||||
} else if errOld != nil && errCur == nil {
|
||||
if hasCatchAllIngressRule(curIng.Spec) && disableCatchAll {
|
||||
klog.InfoS("ignoring update for catch-all ingress because of --disable-catch-all", "ingress", klog.KObj(curIng))
|
||||
return
|
||||
|
|
Loading…
Reference in a new issue