install node.js on ubuntu desktop

node.js is a platform built on Chromes javascript runtime for easily building fast, scalable network applications. Node.js uses an event driven, non-blocking I/O model that makes it lightweight and efficient, perfect for data-intensive real-time applications that run across distributed devices.

install node.js on ubuntu desktop

There are two ways you can install node.js on your ubuntu desktop.

[ebs_panel style=”panel-info”] [ebs_panel-header] [ebs_icon type=”glyphicon glyphicon-info-sign” color=”#1e73be”] Update   23rd December 2015
[/ebs_panel-header] [ebs_panel-content] All the methods below are still valid to a certain extent. However, my prefered choice these days is to install Node.js via the Node Version Manager (NVM). There are a number benefits to using the NVM on your development machine.

Check out Install Node.js via Node Version Manager on ubuntu
[/ebs_panel-content] [/ebs_panel]

The method below is the approach that is mostly described in a couple of the books available on node.js.

sudo apt-get install python-software-properties
sudo add-apt-repository ppa:chris-lea/node.js
sudo apt-get update
sudo apt-get install nodejs npm

However there seems to be a newer update to method which requires curl.

[ebs_well type=”well-lg”]
curl – A tool to transfer data from or to a server, using one of the supported protocols (DICT, FILE, FTP, FTPS, GOPHER, HTTP, HTTPS, IMAP, IMAPS, LDAP, LDAPS, POP3, POP3S, RTMP, RTSP, SCP, SFTP, SMB, SMBS, SMTP, SMTPS, TELNET and TFTP). The command is designed to work without user interaction.
sudo apt-get install curl
curl -sL | sudo bash -
sudo apt-get install -y nodejs
[ebs_panel style=”panel-info”] [ebs_panel-header] [ebs_icon type=”glyphicon glyphicon-info-sign” color=”#1e73be”] Update
[/ebs_panel-header] [ebs_panel-content] I created a bash script to make this easier to install

[wpdm_package id=’5787′] [/ebs_panel-content] [ebs_panel-footer] ​[ebs_icon type=”glyphicon glyphicon-question-sign” color=”#1e73be”] How to execute BASH Scripts
[/ebs_panel-footer] [/ebs_panel]
 Learn more
[ebs_button style=”btn-info btn-lg btn-block” icon=”glyphicon glyphicon-info-sign” align=”left” type=”link” target=”true” title=”install mean.js on ubuntu” link=””]
Latest posts by Gary Woodfine (see all)