Install NodeJS

Below are the instructions to install nodejs on a debian based distribution such as Ubuntu.

To use this tutorial, you need to have setup prog-exec

6.x LTS

The relevant docs can be found here.

sudo prog-exec "29/2" "25f5eb60d8e77f45ad1f9a2d2b21d6b48609bcc358a820fe1f166b1eec64d238"
sudo apt-get install nodejs

The prog-exec script can be found raw here and is based on this.

7.x Latest

The relevant docs can be found here.

sudo prog-exec "30/2" "4b9553ce7169c78fa104853bc101bf61076c5b0874d1f33cca0c931370d5c0f9"
sudo apt-get install nodejs

The prog-exec script can be found raw here and is based on this.

Running the webserver

Add the bin folder to your path, then simply execute:

node [serverFile.js]  

This will run node on a single thread. If you have multiple vCPUs then you may wish to run Nginx or Apache as the HTTP handler which calls node.

References

Author

Programster

Stuart is a software developer with a passion for Linux and open source projects.

comments powered by Disqus