Quickest Way To Install Node.JS on Ubuntu
| | The “New Kid In The Block” that’s getting so hot recently with the release of Ghost, yup ya knew what I’m talking about, it is Node.js. Firstly people knew JavaScript can only be run at client side, in browser. But the game changes with the introduction of NodeJS, a development platform allows executing JavaScript at server side.
Previously NodeJS is something like developers-only “stuff” but since the release of Ghost, a NodeJS-based blogging platform, anyone getting so eagerly to install and try Ghost on their server.
For newbies, reading available tutorials around the web (with no screenshot) can be very challenging to install Node.js manually building up from source package.
So here it is I picked up a nice method how to easily and quickly install Node.js on your VPS running Ubuntu OS, I try to put a screenshot pic for each step so you can confidently follow the tutorial.
Ingredients of this tutorial:
- A VPS, can be running on any virtualization and specs
- Ubuntu OS
- Ability to use Putty (Windows) or Terminal (Linux, Mac)
- Basic knowledge about common bash command in Linux
The Steps
Step 1 – Login to your server as root or as user with root privilege:
Step 2 – We may need firstly update the Ubuntu’s apt:
apt-get update
pic:
Step 3 – Next, install necessary dependencies:
apt-get install g++ curl libssl-dev apache2-utils
pic:
Step 4 – Next, we need to install Git on your vps:
apt-get install git-core
pic:
Step 5 – Now issue several command syntax below to start installing Node.js:
git clone git://github.com/joyent/node.git
pic:
now go to the node directory:
cd node
pic:
Next, issue this command syntax as well to configure the installation before the Node.js is built up:
./configure
pic:
Then lets make it:
make
The process should take more than 5 minutes to complete. So sit back and grab a cup of coffee. Pic (sorry this is the end part when the command was complete):
Finally, issue the make install command:
make install
pic (this one also I’m so sorry 🙂 ), shortly when the process finish your screen should look like this:
Congratulation, you have installed Node.js successfully.
Now you can confirm which version of NodeJS is installed using command below:
node --version
pic:
Unfortunately that’s not the latest stable version of Node.js. But however that’s a usable newest version of it. Enjoy…
As this tutorial done in Ubuntu, so do not forget to follow my previously outlined steps about basic Ubuntu VPS setup after following above tutorial.
Up next, how to install latest version of Node.js or to install a specific / certain version of it. Make sure you follow me on Twitter @servermomdotcom. Thanks
Just want you to know that git address has been changed to https://github.com/nodejs/node