Resolves issue with proxy-redirect nginx configuration

Resolves an issue where the proxy-redirect annotations were not generating the
correct configuration possibly because of user error. This is done by only
setting the proxy_redirect if both proxy-redirect-from and proxy-redirect-to
have valid values. Also adds the e2e tests.

Fixes #2074
This commit is contained in:
Fernando Diaz 2018-04-25 16:38:30 -05:00
parent d577fe2c15
commit e224259e38
6 changed files with 179 additions and 7 deletions

View file

@ -262,7 +262,7 @@ func (f *Framework) matchNginxConditions(name string, matcher func(cfg string) b
glog.Infof("nginx.conf:\n%v", o)
}
if matcher(o) {
if matcher(strings.Join(strings.Fields(o), " ")) {
match = true
}
})