Skip to content

Commit

Permalink
fix: Pass --host=127.0.0.1 to webpack-dev-server
Browse files Browse the repository at this point in the history
Works around connection issue with webpack-dev-server 3.11.0 and Node 17+
  • Loading branch information
Johannes Eriksson committed Jan 12, 2022
1 parent dcc7910 commit ff7b24d
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -728,6 +728,11 @@ private List<String> makeCommands(DeploymentConfiguration config,
command.add("--port");
command.add(String.valueOf(port));
command.add("--watchDogPort=" + watchDog.get().getWatchDogPort());

// Workaround for issue with Node 17 webpack dev server denying
// request to localhost. See https://github.com/vaadin/flow/issues/12546
command.add("--host=127.0.0.1");

command.addAll(Arrays.asList(config
.getStringProperty(SERVLET_PARAMETER_DEVMODE_WEBPACK_OPTIONS,
"-d --inline=false")
Expand Down

0 comments on commit ff7b24d

Please sign in to comment.