Add flag to skip the update of Ingress status on shutdown
This commit is contained in:
parent
ca5f402322
commit
05a976f9e5
4 changed files with 30 additions and 14 deletions
|
|
@ -138,8 +138,9 @@ type Configuration struct {
|
|||
// (for instance NGINX)
|
||||
Backend ingress.Controller
|
||||
|
||||
UpdateStatus bool
|
||||
ElectionID string
|
||||
UpdateStatus bool
|
||||
ElectionID string
|
||||
UpdateStatusOnShutdown bool
|
||||
}
|
||||
|
||||
// newIngressController creates an Ingress controller
|
||||
|
|
@ -307,12 +308,13 @@ func newIngressController(config *Configuration) *GenericController {
|
|||
|
||||
if config.UpdateStatus {
|
||||
ic.syncStatus = status.NewStatusSyncer(status.Config{
|
||||
Client: config.Client,
|
||||
PublishService: ic.cfg.PublishService,
|
||||
IngressLister: ic.ingLister,
|
||||
ElectionID: config.ElectionID,
|
||||
IngressClass: config.IngressClass,
|
||||
DefaultIngressClass: config.DefaultIngressClass,
|
||||
Client: config.Client,
|
||||
PublishService: ic.cfg.PublishService,
|
||||
IngressLister: ic.ingLister,
|
||||
ElectionID: config.ElectionID,
|
||||
IngressClass: config.IngressClass,
|
||||
DefaultIngressClass: config.DefaultIngressClass,
|
||||
UpdateStatusOnShutdown: config.UpdateStatusOnShutdown,
|
||||
})
|
||||
} else {
|
||||
glog.Warning("Update of ingress status is disabled (flag --update-status=false was specified)")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue