Skip to content
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

How to keep origin header? #139

Closed
adamreisnz opened this issue Dec 19, 2016 · 3 comments
Closed

How to keep origin header? #139

adamreisnz opened this issue Dec 19, 2016 · 3 comments

Comments

@adamreisnz
Copy link

I am using the proxy for a development server but am finding that it loses the Origin header along the way. I tried to set it back manually by using the onProxyRes callback in the options, but that didn't seem to work.

Any thoughts on how I can keep the origin header on the forwarded request?

@chimurai
Copy link
Owner

chimurai commented Dec 19, 2016

Sounds very similar to facebook/create-react-app#1212

http-proxy provides the actual proxy functionality.
Fixing it in the http-proxy project would benefit a broader audience.

Can you create an issue at https://github.com/nodejitsu/node-http-proxy/issues ?

@adamreisnz
Copy link
Author

Indeed, I will file it there, thanks

@adamreisnz
Copy link
Author

It seems it was user error, I was using proxyRes instead of proxyReq to set the header, but proxyRes is the actual response from the target.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants