Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
NodeJS http-server
// install the node http-server server
npm -g install http-server
// run this server:
http-server
// get the process that has bound to the required port
lsof -Pi | grep LISTEN
...
node 18740 Leo 12u IPv4 0xaf78c883a32c84bf 0t0 TCP *:8081 (LISTEN)
...
// kill process (or cmd+c)
kill -9 18740
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment