-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New proxy library in 1.15 isn't backwards-compatible #562
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
Comments
I've just found this same issue, @mzgoddard helped me. This was apparently introduced migrating from http-proxy to http-proxy-middleware. (7b3f12e) It looks like this In the meanwhile can we set a translation for this pattern to match |
at least |
Also in version 2.1.0-beta.0 |
:/ This is a fairly annoying breaking change to just automatically get - I would appreciate at least a warning if using |
Changing * or /* to ** solved the HPM the error but bypass doesn't do anything anymore. Everything is sent to the proxy. |
I've used the custom matching option of the proxy middleware instead of the ...
proxy: [
{
context: function(pathname, req) {
// only proxy the api and the login post call to the node backend
return pathname.match("^/api") || (pathname.match("^/login") && req.method === "POST")
},
target: {
port: 3000
}
}
]
... Hope this helps anyone. |
Hm, sorry that this happened. In PR #359, which implemented the switch from As for the |
I was surprised by this too, only by stumbling across this issue did I understand what had happened. Also, I think the webpack-dev-server documentation is now inconsistent, since the
|
@aknuds1, see my comment above. It is getting fixed ;). |
@SpaceK33z Yeah I saw that, but the webpack-dev-server documentation is still inconsistent, isn't it? It confused me quite a bit when I was re-reading it, to figure out what might be happening. |
Ah yeah, true, that should be fixed now. |
@SpaceK33z Thanks! |
It works for me! Thanks, @SpaceK33z! |
@Mischi and me are also having issues when using a proxy and HTTPS with own certificates (key, crt and ca). With 1.14.2 we could do a redirect from localhost/abc to localhost:
now we are getting
on the console and
inside the browser. |
@davidreher, this could be related to #566. As a workaround, you can use |
@SpaceK33z |
This problem has been fixed with |
The new proxy library used in 1.15 uses a different glob syntax, so this configuration:
works in 1.14, but not 1.15. In 1.15, it needs to be
**
instead of*
.Should we add a warning or something to aid in upgrading?
The text was updated successfully, but these errors were encountered: