-
Notifications
You must be signed in to change notification settings - Fork 994
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refs #12364 - Allow running webpack dev server on any hostname
Currently, SecureHeaders only allows running the webpack dev server from localhost or 0.0.0.0, and only using http. This leads to issues when attempting to run foreman inside a virtual machine or using https. This patch will generate the correct headers during runtime, to allow the dev server to be run on the same host and protocol as the request uses.
- Loading branch information
Showing
4 changed files
with
6 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
# Run Rails & Webpack concurrently | ||
# If you wish to use a different server then the default, use e.g. `export RAILS_STARTUP='puma -w 3 -p 3000 --preload'` | ||
rails: [ -n "$RAILS_STARTUP" ] && $RAILS_STARTUP || bin/rails server -b 0.0.0.0 | ||
webpack: ./node_modules/.bin/webpack-dev-server --config config/webpack.config.js --host=0.0.0.0 | ||
webpack: ./node_modules/.bin/webpack-dev-server --config config/webpack.config.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters