Taught you how to build GitLab
1. Install SSH
sudo yum install -y curl policycoreutils-pythonopenssh-server
2. Start SSH
sudo systemctl start sshd
3. Set the SSH service to start automatically
sudo systemctl enable sshd
4. Install a firewall
sudo yum install firewalld systemd -y
5. Turn on the firewall
service firewalld start
if an error Redirecting to / bin / systemctl start firewalld.service
start with systemctl way: sudo systemctl start firewalld
6. Add the http service to firewalld
pemmanent permanent representation
Without -permanent will fail after the system reboots.
sudo firewall-cmd --permanent --add-service=http
7. Restart the firewall
sudo systemctl reload firewalld
8. Install the notification mail is sent to Postfix
sudo yum install postfix
9. Set the postfix service boot
sudo systemctl enable postfix
10. Start postfix
Start postfix systemctl sudo
postfix start failure Centos start postfix solution fails
11. Install wget
sudo yum -y install wget
12. Installation vim editor
sudo yum install vim -y
13. Add mirror gitlab
wget https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el7/gitlab-ce-10.0.0-ce.0.el7.x86_64.rpm
14. Installation gitlab
rpm -i gitlab-ce-10.0.0-ce.0.el7.x86_64.rpm
Error message
warning: gitlab-ce-10.0.0-ce.0.el7.x86_64.rpm: Header V4 RSA/SHA1 Signature, key ID f27eab47: NOKEY
error: Failed dependencies:
policycoreutils-python is needed by gitlab-ce-10.0.0-ce.0.el7.x86_64
Installation gitlab dependencies
sudo yum install policycoreutils-python
15. gitlab modify the configuration file to specify the server ip and port
vim /etc/gitlab/gitlab.rb
modify external_url 'http: // server ip: port'
to modify external_url 'http: // domain'
16. Reset and start GitLab
gitlab-ctl reconfigure
gitlab-ctl restart
17. Access GitLab
If there is no domain name, specify directly enter the server ip and port access to
initial accounts: root password:! 5iveL fe
first login follow the prompts to change the password
Access failure
If you use the server ip + port visit
to check the server port is open, for example external_url 'http: // server ip: 8000, port 8000 is open to check
if the use of domain names
to check server port 3306 is open external_url' http: // domain, the default port 3306