The minimum memory size of the server is 4 GB. Or 502!
Let’s go
- The following command will enable HTTP, HTTPS, and SSH access in the system firewall.Problems encountered in the current step
Openssh-server yum install -y curl policycoreutils-python openssh-server The service is set to start systemctl upon startupenableSSHD // Start the SSH service systemctl start SSHD // Add HTTP or HTTPS services to Firewalld. Permanent indicates that the service takes effect permanently. If you do not add --permanent, the system becomes invalid after the next startup. Firewall-cmd --permanent --add-service= HTTP firewall-cmd --permanent --add-service= HTTPS // Restart firewall systemctl reload firewalldCopy the code
- Install Postfix to send notification emails.
Postfix yum install postfix postfix yum install postfix postfix yum install postfixenablePostfix // Start postfix systemctl start postfixCopy the code
- Install wget for downloading plug-ins from the Internet.
yum -y install wget Copy the code
- Install the Vim editor.
yum install vim -y Copy the code
- Add the GitLab package repository and install the installation packages.Each version of the installation package
// Add GitLab image wget -- Content-disposition HTTP: / / https://packages.gitlab.com/gitlab/gitlab-ce/packages/el/6/gitlab-ce-12.10.3-ce.0.el6.x86_64.rpm/download.rpm / / installation GitLab RPM -i GitLab - ce - 12.10.3 - ce. 0. El6. X86_64. RPMCopy the code
- Modify GitLab configuration file to specify server IP and custom port.Problems encountered in the current step
If 8080 is used, change it to another port and enable the corresponding port on the firewall vim /etc/gitlab/gitlab.rb // Change external_url in the configuration file'http://ip:port'// Gitlab-ctl reconfigure // gitlab-ctl restartCopy the code
- Tests whether it is accessible.Problems encountered in the current step
curl localhost:port/gitlab Copy the code
- If the following information is displayed, it is successful.
- Page visit GitLab
- If no domain name is available, enter the server IP address and port number
- The first access redirects directly to the Change Password screen to change the password
Problems encountered
-
perform
firewall-cmd --permanent --add-service=http
When promptFirewallD is not running
The firewall is not enabled- through
systemctl status firewalld
The firewalld is in dead state, that is, the firewall is disabled. - through
systemctl start firewalld
Enable the firewall. - Again through
systemctl status firewalld
Check firewalld status. If running is displayed, firewalld is enabled.
- through
-
perform
gitlab-ctl reconfigure
When promptedruby_block[wait for redis service socket] action run
Ctrl + C
End forcibly.- perform
systemctl restart gitlab-runsvdir
- Performed again
gitlab-ctl reconfigure
- Performed again
gitlab-ctl restart
-
perform
gitlab-ctl restart
promptwarning: redis: unable to open supervise/ok: file does not exist
- The solution is the same as problem 2
-
If Linux is accessible, but remote access is not: this is probably because Centos firewall does not have open port numbers.
- perform
firewall-cmd --zone=public --add-port=8090/tcp --permanent
--zone // scope
--add-port=8090/ TCP // Add a port in the format of port/communication protocol
--permanent // The parameter takes effect permanently. If this parameter is not specified, the parameter becomes invalid after the system restarts
Systemctl stop firewalld.service // Disable the firewall
Systemctl start firewalld.service // Start the firewall
Firewall-cmd --reload // Restart the firewall
Firewall-cmd --zone=public --query-port=80/ TCP // Check whether the port is enabled on the firewall. Yes indicates that the port is enabled
- perform
-
GitLab clears the cache
gitlab-rake cache:clear