mirror of https://github.com/caddyserver/caddy.git
fastcgi: Redirect using original URI path (fix #5073)
This commit is contained in:
parent
eead00f54a
commit
f7c1a51efb
|
@ -348,7 +348,7 @@ func parsePHPFastCGI(h httpcaddyfile.Helper) ([]httpcaddyfile.ConfigValue, error
|
||||||
}
|
}
|
||||||
redirHandler := caddyhttp.StaticResponse{
|
redirHandler := caddyhttp.StaticResponse{
|
||||||
StatusCode: caddyhttp.WeakString(strconv.Itoa(http.StatusPermanentRedirect)),
|
StatusCode: caddyhttp.WeakString(strconv.Itoa(http.StatusPermanentRedirect)),
|
||||||
Headers: http.Header{"Location": []string{"{http.request.uri.path}/"}},
|
Headers: http.Header{"Location": []string{"{http.request.orig_uri.path}/"}},
|
||||||
}
|
}
|
||||||
redirRoute := caddyhttp.Route{
|
redirRoute := caddyhttp.Route{
|
||||||
MatcherSetsRaw: []caddy.ModuleMap{redirMatcherSet},
|
MatcherSetsRaw: []caddy.ModuleMap{redirMatcherSet},
|
||||||
|
|
Loading…
Reference in New Issue