Server still running after stopping Nodemon
See original GitHub issuenodemon -v
: 2.0.7node -v
: 14.17.0- Operating system/terminal environment: WSL2 Ubuntu 20.04
Expected behaviour
The server stops after using ctrl + c
, and not run in background
Actual behaviour
The server doesn’t stops after ctrl + c
and it keeps runs in background even after uninstalling
Steps to reproduce
I started the server using nodemon and my script was "server": "npx nodemon app.js"
and ran npm server start
But server is still running in the Browser, I can’t start any other server on that same port i.e 3000
app.js is a simple express app
Issue Analytics
- State:
- Created 2 years ago
- Comments:11 (5 by maintainers)
Top Results From Across the Web
node.js - Can't stop server running by nodemon - Stack Overflow
I add nodemon for automatically run server then run test. But have error when run gulp task again. I have error that the...
Read more >Automatically restart Node.js apps with Nodemon
The essential tutorial for Nodemon, a utility for Node.js applications that monitors for changes and automatically restarts the server.
Read more >nodemon events — run tasks at server start, restart, crash, exit
Because nodemon doesn't run npm start-dev when it restarts the server, the pre command isn't run either. So this works only the first...
Read more >How to kill server when seeing “EADDRINUSE: address ...
A tutorial on how to kill the process manually when “EADDRINUSE” happens on Mac/Linux and Windows. Nodejs listen EADDRINUSE: address already in ...
Read more >nodemon - npm
Whilst nodemon is running, if you need to manually restart your application, instead of stopping and restart nodemon, you can type rs with...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Well, it’s not
After further tests using the repo above it seems that nodemon works just fine. Using
nodemon index.js
the server does restart as expected. So the issue is more onnpm-watch
, for me at least.https://user-images.githubusercontent.com/75162562/125225811-2b274180-e2d0-11eb-9987-bc6c23e9cda8.mp4