I'm getting some random errors when running:
forge run web
in my app.
$ forge run web
[ INFO] Forge tools running at version 3.3.11
[ INFO] Checking JavaScript files...
[ INFO] JavaScript check complete
[ INFO] Verifying your configuration settings...
[ INFO] Configuration settings check complete
[ INFO] { [Error: listen EADDRINUSE] code: 'EADDRINUSE', errno: 'EADDRINUSE', syscall: 'listen' }
Any idea what might cause this error?
The error is cause by an application already listening on the port you're trying to listen on.
You can use ps aux | grep node
to see if there are any node processes running.
Then kill them using kill pid
where pid is the process id
example:
ps aux | grep node
37211 0.0 0.2 3029484 17852 s018 S+ 5:35PM 0:00.28 node ./web.js
kill 37211