Skip to content

Honor X-Forwarded-Prefix header #6908

@Shayan-To

Description

@Shayan-To

I'm using Caddy behind an Nginx reverse proxy. Nginx is stripping a path prefix (e.g. /blog), and setting X-Forwarded-Prefix header (e.g. X-Forwarded-Prefix: /blog).

My problem is that when Caddy is trying to return a redirect response (30X), the location does not honor the path prefix. For example if I try to get /blog/wp-content, it is redirected to /wp-content/ and not /blog/wp-content/.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions