Fix sticky session not set for host in server-alias annotation (#6448)
This commit is contained in:
parent
9c0a39636d
commit
44aaa2e367
2 changed files with 50 additions and 0 deletions
|
|
@ -651,6 +651,15 @@ func (n *NGINXController) getBackendServers(ingresses []*ingress.Ingress) ([]*in
|
|||
locs[host] = []string{}
|
||||
}
|
||||
locs[host] = append(locs[host], path.Path)
|
||||
|
||||
if len(server.Aliases) > 0 {
|
||||
for _, alias := range server.Aliases {
|
||||
if _, ok := locs[alias]; !ok {
|
||||
locs[alias] = []string{}
|
||||
}
|
||||
locs[alias] = append(locs[alias], path.Path)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue