-
Notifications
You must be signed in to change notification settings - Fork 619
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
X-Forwarded-Prefix header support #304
Comments
How many of these headers are there? :) What would it need to contain? The original request path? |
In my personal case i'd like to have the same behaviour that i had with Zuul :) btw, as far as i know, the following list are usually added:
Another important point is that you have to keep those headers from upstream proxy (if fabio itself is placed behind proxy). In this case i should have two X-Forwarded-*** headers, one from upstream proxy and another one from fabio. |
This patch adds the X-Forwarded-Prefix header to upstream requests which contains the unmodified url path from the original request. Fixes #304
@avarabyeu pushed a change with test. If you could verify that it works for you then I'll merge it and include it in the next release which I'll roll this week. |
@magiconair Just checked it. Seems like i didn't understand your question about original request path :) Header is added, but value should contain only the part that was truncated by proxy. Also, it should be added only in case prefix is being stripped. btw, thanks a lot for prompt answers! |
|
Ah, you want the stripped prefix to be in the header, e.g. |
@avarabyeu I've pushed an update to the branch. Can you check, please? |
@magiconair Checked. Works as expected! Thank you very much, looking forward for the release. |
While using fabio with urlprefix option, X-Forwarded-Prefix header is not passed to downstream requests.
In this case downstream services are not able to generate correct back-links since they don't know their real path.
The text was updated successfully, but these errors were encountered: