fix route conflict

This commit is contained in:
fatedier 2019-03-29 17:12:44 +08:00
parent 9cee263c91
commit 74a8752570
2 changed files with 8 additions and 0 deletions

View File

@ -51,6 +51,10 @@ func (pxy *HttpProxy) Run() (remoteAddr string, err error) {
addrs := make([]string, 0)
for _, domain := range pxy.cfg.CustomDomains {
if domain == "" {
continue
}
routeConfig.Domain = domain
for _, location := range locations {
routeConfig.Location = location

View File

@ -33,6 +33,10 @@ func (pxy *HttpsProxy) Run() (remoteAddr string, err error) {
addrs := make([]string, 0)
for _, domain := range pxy.cfg.CustomDomains {
if domain == "" {
continue
}
routeConfig.Domain = domain
l, errRet := pxy.rc.VhostHttpsMuxer.Listen(routeConfig)
if errRet != nil {