do not require --default-backend-service
This commit is contained in:
parent
5ce3809457
commit
b3a22f7fc0
9 changed files with 97 additions and 143 deletions
|
|
@ -362,6 +362,12 @@ func (n *NGINXController) getDefaultUpstream() *ingress.Backend {
|
|||
Name: defUpstreamName,
|
||||
}
|
||||
svcKey := n.cfg.DefaultService
|
||||
|
||||
if len(svcKey) == 0 {
|
||||
upstream.Endpoints = append(upstream.Endpoints, n.DefaultEndpoint())
|
||||
return upstream
|
||||
}
|
||||
|
||||
svc, err := n.store.GetService(svcKey)
|
||||
if err != nil {
|
||||
glog.Warningf("Error getting default backend %q: %v", svcKey, err)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue