in Javascript, Tutorials

Install Node.js From Source via GIT

Yeah!!! I am going to give to try Node.js by creating small product. But don’t have Node.js developing environment ready in my work station. So, I installed by compiling from source via GIT repo. I can switch and update it easily. It’s quite easy. Just follow me.

If you don’t have installed GIT in your pc, then run the following commands, neither skip the following commands…

sudo apt-get update
sudo apt-get install build-essential openssl libssl-dev pkg-config git-core

GIT installation is done. Now, clone the repository at /usr/local/src.

cd /usr/local/src
sudo git clone git://

Run the configure scritp which will actually ensure that nodejs is install globally in the system’s environment.

sudo ./configure

Then, run the following command for compiling and installing it…

sudo make
sudo make install

One of the main reasons to choice GIT is that easy updating nodejs. It’s make easy updating the nodejs.
Just you will have to pull the latest source codes. And then repeat the whole installation process..

cd /usr/local/src/node
sudo git pull origin master
sudo ./configure
sudo make
sudo make install

Update and re-installation is done. Let’s make an example to test that nodejs is working well.

cat > ~/server.js <

Now open the browser, type http://localhost:1337. You will get “Hello world”. it’s done 🙂

Write a Comment



  1. I’m curious to find out what blog platform you have been using?

    I’m having some minor security problems with my latest site
    and I’d like to find something more secure. Do you have any solutions?