Node was installed at
/usr/local/bin/node
npm was installed at
/usr/local/bin/npm
Make sure that /usr/local/bin is in your $PATH.
var http = require('http');
// create http server
http.createServer(function(req, res) {
// content header
res.writeHead(200, {
'content-type': 'text/plain'
});
// write message and signal communication is complete
res.end("Hello, World!\n");
}).listen(8124);
console.log('Server running on 8124/');