Installing Latest Node.js on UbuntuWeb DevelopmentUbuntu
Updated on Friday, August 30, 2013
If you’d like to try this tutorial on our public cloud, we’re currently offering a free $10.00 credit for signing up. You’ll be able to start up a cloud server, create virtual networks, use load balancers and more within seconds after you sign up on our OpenStack® public cloud.
There are a lot of tutorials suggesting compiling from source, we strongly advise again that. For most of the time, package maintainers know the software very well and you’ll get the latest release without having to compile from scratch.
The following will work on any release of Ubuntu, including Ubuntu 12.04 LTS, Ubuntu 12.10 and Ubuntu 13.04. It will help you install Node.js on Ubuntu without compiling from source. You can run the following command on your cloud server to get started and install the latest Node.js release on your server:
$ apt-get update $ apt-get install -y python-software-properties software-properties-common $ add-apt-repository ppa:chris-lea/node.js $ apt-get update $ apt-get install nodejs
That’s it! Once you’ve done that, you’ll be rolling with the latest stable Node.js release without having to worry about compiling anything. If you need to upgrade Node.js at anytime when a new release comes out, you can do it directly from the package manager, without having to recompile from scratch. Just another reason why you should always look for packages before installing from source.