Let's start step by step:
Step 1: Install and Configure Required Dependencies
Using yum utility we will guarantee the mandatory dependencies GIT have for a normal use
Enter as root user to the CentOS 7 linux server
#yum install curl policycoreutils-python openssh-server
you will see
Complete!
[root@demodb ~]# Transaction test succeeded
Now, install Postfix service to send notification emails, and enable it to start at system boot, then check if it's up and running using following commands.
# yum install postfix
# systemctl start postfix
# systemctl enable postfix
# systemctl status postfix
At the end you will see something like this:
[root@demodb ~]# systemctl status postfix
● postfix.service - Postfix Mail Transport Agent
Loaded: loaded (/usr/lib/systemd/system/postfix.service; enabled; vendor preset: disabled)
Active: active (running) since Sun 2019-07-28 11:09:08 COT; 1min 31s ago
Main PID: 8898 (master)
CGroup: /system.slice/postfix.service
├─8898 /usr/libexec/postfix/master -w
├─8899 pickup -l -t unix -u
└─8900 qmgr -l -t unix -u
Step 2: Add GitLab Repository and Install Package
#curl https://packages.gitlab.com/install/repositories/gitlab/gitlab-ce/script.rpm.sh | sudo bash
Until the process finish with
The repository is setup! You can now install packages.
#
#EXTERNAL_URL="http://gitlab.demodb.com" yum install -y gitlab-ce
This process takes several minutes, depends on your Linux, Internet broadband and CPU's power
_______ __ __ __
/ ____(_) /_/ / ____ _/ /_
/ / __/ / __/ / / __ `/ __ \
/ /_/ / / /_/ /___/ /_/ / /_/ /
\____/_/\__/_____/\__,_/_.___/
Thank you for installing GitLab!
GitLab should be available at http://192.168.1.101
For a comprehensive list of configuration options please see the Omnibus GitLab readme
https://gitlab.com/gitlab-org/omnibus-gitlab/blob/master/README.md
Verifying : gitlab-ce-12.1.1-ce.0.el7.x86_64 1/1
Installed:
gitlab-ce.x86_64 0:12.1.1-ce.0.el7
Complete!
Note: If you want to change your main URL, you can configure it in the GitLab main configuration file /etc/gitlab/gitlab.rb in the external_url section. Once changed, don’t forget to reconfigure gitlab to apply the recent changes in the configuration file using the following command.
In my case I changed the port number 8080 for 5010, so look for 8080 and change it for the port number you need, then execute the following command
#gitlab-ctl reconfigure
Check if you have a system firewall enabled because you need to open port 5010 (HTTP) and 5443 (HTTPS) to allow connections in the system firewall.
#firewall-cmd --permanent --add-service=5010/tcp
#firewall-cmd --permanent --add-service=5443/tcp
#systemctl reload firewalld
Step 3: Initial Gitlab Setup
Go to the Internet Browser using the URL you defined previously
http://localhost:5010 and follow the instructions creating first the admin user, then the project
and good Luck!