Properly set ing.Service when there are multiple rules with different hosts using the same path

Fixes #3611

Signed-off-by: Alejandro Pedraza <alejandro.pedraza@gmail.com>
This commit is contained in:
Alejandro Pedraza 2019-02-06 17:34:14 -05:00
parent ef0b1633e2
commit a3c87cf9cb
2 changed files with 12 additions and 2 deletions

View file

@ -1014,7 +1014,7 @@ stream {
{{ end }}
location {{ $path }} {
{{ $ing := (getIngressInformation $location.Ingress $location.Path) }}
{{ $ing := (getIngressInformation $location.Ingress $server.Hostname $location.Path) }}
set $namespace "{{ $ing.Namespace }}";
set $ingress_name "{{ $ing.Rule }}";
set $service_name "{{ $ing.Service }}";