reverse_proxy: Add support for SRV backends (#3180)

* reverse_proxy: Begin SRV lookup support (WIP)

* reverse_proxy: Finish adding support for SRV-based backends (#3179)
This commit is contained in:
Matt Holt
2020-03-24 10:53:53 -06:00
committed by GitHub
parent 95b2863df2
commit e02117cb8a
4 changed files with 78 additions and 29 deletions

View File

@ -313,7 +313,7 @@ func (h *Handler) ServeHTTP(w http.ResponseWriter, r *http.Request, next caddyht
// the dial address may vary per-request if placeholders are
// used, so perform those replacements here; the resulting
// DialInfo struct should have valid network address syntax
dialInfo, err := fillDialInfo(upstream, repl)
dialInfo, err := upstream.fillDialInfo(r)
if err != nil {
return fmt.Errorf("making dial info: %v", err)
}