Welcome to the rails deployment series. Today, we will be installing Git on your remote server. I am not going to go into the debate of SVN vs Git. *yawnz. The purpose of installing Git in the remote server is mainly cuz my local runs Git as well and I will also be installing Gitosis in the remote server to act as a repo where I can push changes to.
Deploying Rails to Centos 5
- Part 1 // Apache
- Part 2 // mySQL
- You are here!
- Part 4 // Ruby, Gems & Rails
- Part 5 // Passenger
- Part 6 // Gitosis
- Part 7 // Capistrano
So to start off, make sure you have all the dependencies by installing
yum install curl-devel expat-devel gettext-devel \ openssl-devel zlib-devel
Head to http://git-scm.com/download and grab the latest link for Linux. The link is at the top right sidebar. Took me a while to find it. darn. lol.
Once it is downloaded, you can install it by running
tar -jxf git-126.96.36.199.tar.bz cd git-188.8.131.52 make prefix=/usr/local all sudo make prefix=/usr/local install
Make sure you type in your git archive’s name, and not the one in the code above. 😀
When the installation is done, you can now safely remove the tar files and the
git-184.108.40.206 folder by doing
rm git-220.127.116.11.tar.gz rm -rf git-18.104.22.168
Once you are done installing, you can check if you have git install by running
You are done for now! Leave git alone and let’s install some rubies and rails!