I have just installed dockers and installed node. I am able to run a basic express site. My issue now is I can\'t stop it. Control-C is not doing anything.
Temporarily w
I came across this same problem today, and struggled to find an explanation/solution. I discovered (through trial and error) that this only occurs when the CMD in the Dockerfile is set to:
CMD [ "node", "server.js" ]
However, Ctrl+C works fine when the CMD is changed to:
CMD [ "npm", "start" ]
The npm start
script in my package.json
file is set to node server.js
, so I have no idea why this change works, but hopefully this helps.