

Our git server has been successfully configured and we have created an empty repository for our first git project.Ĭonnect to using ssh with root user.Ĭonfigure name resolution by adding following line in /etc/hosts. Git access remote repositories via ssh service, therefore, no explicit Linux firewall configuration is required. While a shared repository is used to allow project members to push changes to the git server.Įnable post-update hook by copying the sample file as follows: $ cd ~/repo/project1/hooks/ Note: A bare repository has no working area, therefore, it is not possible to add files to it locally. Then, we have created a bare repository for our project1 project. Here, we have created a directory repo to keep all of our projects' repositories in a single place. Initialized empty shared Git repository in /home/git/repo/project1/ Now, login with git user and create a local git Repository.

Passwd: all authentication tokens updated successfully. Therefore, we add git user and set the password as follows: # useradd gitīAD PASSWORD: The password is shorter than 8 characters We need a user to own our git repository. Git rpm is provided in RHEL/CentOS ISO, therefore we can easily install git from a local yum repository.Ĭonnect to using ssh, and install git by using yum command.
