Merge pull request #1123 from diazjf/server-alias

Add support for Server Alias in Nginx
This commit is contained in:
Manuel Alejandro de Brito Fontes 2017-08-19 14:47:23 -04:00 committed by GitHub
commit f6413e292f
9 changed files with 360 additions and 206 deletions

View file

@ -446,6 +446,7 @@ func (n *NGINXController) OnUpdate(ingressCfg ingress.Configuration) error {
IP: svc.Spec.ClusterIP,
Port: port,
ProxyProtocol: false,
})
}

View file

@ -147,6 +147,9 @@ var (
"toLower": strings.ToLower,
"formatIP": formatIP,
"buildNextUpstream": buildNextUpstream,
"serverConfig": func(all config.TemplateConfig, server *ingress.Server) interface{} {
return struct { First, Second interface{} } { all, server }
},
}
)
@ -499,4 +502,4 @@ func buildNextUpstream(input interface{}) string {
}
return strings.Join(nextUpstreamCodes, " ")
}
}