Skip to content

Commit

Permalink
dont use reversed Host header for files services
Browse files Browse the repository at this point in the history
  • Loading branch information
rgaudin committed Feb 5, 2024
1 parent 4843434 commit 77b6f29
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions reverse-proxy/gen-caddyfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,8 +165,10 @@ def should_protect(self) -> bool:
{{subdomain}}.{$FQDN}:80, {{subdomain}}.{$FQDN}:443 {
tls internal
log
reverse_proxy files:80
rewrite * /{{folder}}/{path}?{query}
reverse_proxy files:80 {
rewrite /{{folder}}/{path}?{query}
header_up Host {upstream_hostport}
}
handle_errors {
respond "HTTP {http.error.status_code} Error ({http.error.message})"
}
Expand Down

0 comments on commit 77b6f29

Please sign in to comment.