Skip to content

Commit 0593464

Browse files
authored
Making it work for non Linux proxied environments
0.0.0.0 only works on Linux so it's changed by 127.0.0.1 (this fork was born from a rejected PR: joeferner#300)
1 parent 128580a commit 0593464

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/proxy.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ export class Proxy implements IProxy {
216216
// port 0 to get the first available port
217217
const listenOptions = {
218218
port: 0,
219-
host: "0.0.0.0",
219+
host: "127.0.0.1",
220220
};
221221
if (this.httpsPort && !options.hosts) {
222222
listenOptions.port = this.httpsPort;
@@ -487,7 +487,7 @@ export class Proxy implements IProxy {
487487
const conn = net.connect(
488488
{
489489
port,
490-
host: "0.0.0.0",
490+
host: "127.0.0.1",
491491
allowHalfOpen: true,
492492
},
493493

0 commit comments

Comments
 (0)