-
-
Notifications
You must be signed in to change notification settings - Fork 6.3k
The default port 8080 cannot work #36
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
What OS are you on? |
i can see nothing in the browser with any ports.
|
In |
@yyx990803 Great, it works, but can you explain why to remove the |
I am using the simple-webpack template. No |
the same problem when using the simple-webpack template |
This issue has gotten a little stale and it seems to be chronicling problems with two separate templates, so I'm closing. If anyone is still experiencing a problem (or has found a solution to a problem), please post an issue or pull request for the appropriate template here. 😃 |
Removed option "-a localhost", because this dns isn't recognized by docker Removing this option makes http-server defaults to 127.0.0.1 vuejs/vue-cli#36
On Windows 10, I had the same with 8080 already in use. After vue init webpack I was unable to start the build server with error : EADDRINUSE. In the config folder, index.js file I changed the de object, port key to 8081 and it fixed it for me. Changed from: dev: { to: dev: { |
If you're using vue init webpack-simple {{project_name}} with vue-cli, also checkout node_modules >> webpack-dev-server >> bin >> webpack-dev-server.js line 62 for the port number. |
This is one of those things that always seem odd to me in boilerplates. Why not make it dynamic so it finds an open port on it's own? it's pretty easy implementation. I could PR it for the webpack template. |
@adi518 I think a PR would be welcome and should indeed be easy using portfinder. |
When using the webpack-simple template, you can add a "port" property to the devServer object in webpack.config.js and assign it to whatever value you want, like so:
|
This issue might be closed, but i found a work around for the same issue using webpack-simple. OS: Mac OS X project-name/node_modules/webpack-dev-server/bin/webpack-dev-server.js |
Under What you need is right here. |
Cool, good to know. Was just learning vue and related frameworks. Couldn't find any solution and that worked for me. Thanks for the suggestion. |
i take a vue project from git and when i run it .it gives me http://192.168.1.33:8080/sockjs-node and the project is not in this link |
But there is nothing except '}' in line 62 |
Do this: 1.remove your Node.js and again install latest version here link to install Node.js 2.On the installation path choose npm package manager and install 3.open cmd and inter
4.after install vue cli (Previous step)inter to cmd
6.so inter in cmd
7.the you'll see localhost page Local host:http://localhost:8080/) code here` |
The
npm run dev
command can run without any problem, but i can see nothing in the browser withlocalhost:8080
.The
lsof
command shows:So i'm sure no other applications bind this port, when i change the port in dev-server.js to 8090, it worked.
The text was updated successfully, but these errors were encountered: