Installing GITLab on CentOS

What Is GIT ?

Git is a web-based Git repository hosting service, which offers all of the distributed revision control and source code management (SCM) functionality of Git as well as adding its own features. Unlike Git, which is strictly a command-line tool, GitHub provides a web-based graphical interface and desktop as well as mobile integration. It also provides access control and several collaboration features such as wikis, task management, and bug tracking and feature requests for every project. Git is one of the best solution available for your SCM.

Installation on CentOS.


Now we will be Installing GITLab on CentOS, before we proceed to gitlab installation we have to install following services, make sure you have opened firewall ports 80 (http) and 22 (ssh). Now just execute following commands on shell,

sudo yum install openssh-server
sudo yum install postfix
sudo yum install cronie
sudo service postfix start
sudo chkconfig postfix on

Now we will install Gitlab Community edition on CentOS release 6.6 (Final) for setting up private hosted git server. Go to following url,

select operating system as give in following image,


The above image provide full installation guide, if you follow it correctly you will get successful git installation. here we proceed to rest of setup, after installation of prerequisite now we will download and install gitlab rpm by following commands,

curl -O

sudo rpm -i gitlab-7.9.2_omnibus-1.el6.x86_64.rpm

Configure Git by executing following command,

sudo gitlab-ctl reconfigure

now we will configure git url for accessing it on browser, remember gitlab community edition uses nginx webserver. we will access following file and change url.

vim /var/opt/gitlab/nginx/conf/gitlab-http.conf

on the server block of virtual host we will add ip address to access gitlab,

server {

now save the file and run following command,

gitlab-ctl restart

now access url it will take you to git login page, use following credentials,

Username: root

Password: 5iveL!fe




after login don’t forget to change password. here you have successfully installed Gitlab community edition. If you have any issues feel free to comment below.


  1. This is very helpful to me. i followed it and successfully installed git on my server. Thanks Thumbs up !

Leave a Reply

Your email address will not be published.

Solve : *
32 ⁄ 8 =