-
Notifications
You must be signed in to change notification settings - Fork 823
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
proxy to https errors in Node 0.12 #24
Comments
btw, |
Don't think it is an issue of the middleware. Looking at the http-proxy proxy-http-to-https.js example, you'll need to configure the var https = require('https');
var myProxy = httpProxyMiddleware('/my-path', {
target: 'https://mysslexample.com',
agent : https.globalAgent // <-- agent
}); |
ahh thanks for pointing me to that example. i also needed to set the |
@chimurai thanks for the agent tips, and thanks to @noahgrant for the host header information. |
Hi,
When proxying to https, ie:
var myProxy = httpProxyMiddleware('/my-path', {target: 'https://mysslexample.com'});
I first get a 'Proxy created' message, but then when I try to go to
/my-path
, I get the following error:[HPM] Proxy error: undefined mysslexample.com/my-path
and nothing works. It works in Node 0.10.33, but not in Node 0.12. Is this an http-proxy-middleware issue or an http-proxy issue?
Thanks!
The text was updated successfully, but these errors were encountered: