Guys,
I'm trying to do ngrok 9090 with webpack-dev-server and it doesn't connect.
package.json
"scripts": {
"build": "webpack",
"dev": "webpack-dev-server --devtool eval --progress --colors --hot --content-base build"
}
webpack.config.js
var path = require('path');
module.exports = {
devServer: {
host: '0.0.0.0',
port: 9090
},
entry: ['webpack/hot/dev-server', path.resolve(__dirname, 'app/app.js')],
output: {
path: path.resolve(__dirname, 'build'),
filename: 'bundle.js'
},
module: {
...
}
};
Am I missing something here?
I've run into this issue as well and this is how I've gotta around it:
$ ngrok tcp 3000
Which will return a URL like: tcp://0.tcp.ngrok.io:48528 -> localhost:3000
In your browser, you should visit: https://0.tcp.ngrok.io:48528
This will not hot reload by default -- you have to update your webpack config to point to ngrok (instead of localhost, etc).
@nickpresta thanks!
@nickpresta
@henriquea
hi please send here some example
Most helpful comment
I've run into this issue as well and this is how I've gotta around it:
Which will return a URL like:
tcp://0.tcp.ngrok.io:48528 -> localhost:3000In your browser, you should visit:
https://0.tcp.ngrok.io:48528This will not hot reload by default -- you have to update your webpack config to point to ngrok (instead of localhost, etc).