Commit 62622eb8 authored by Matthew Holt's avatar Matthew Holt

proxy: 'transparent' also sets X-Forwarded-For (closes #924)

parent 87c389f7
......@@ -289,6 +289,7 @@ func parseBlock(c *caddyfile.Dispenser, u *staticUpstream) error {
case "transparent":
u.upstreamHeaders.Add("Host", "{host}")
u.upstreamHeaders.Add("X-Real-IP", "{remote}")
u.upstreamHeaders.Add("X-Forwarded-For", "{remote}")
u.upstreamHeaders.Add("X-Forwarded-Proto", "{scheme}")
case "websocket":
u.upstreamHeaders.Add("Connection", "{>Connection}")
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment