修改主机名
[root@localhost ~]# hostnamectl --static set-hostname cicd-gitlab
添加本地解析
[root@cicd-gitlab ~]# vim /etc/hosts 192.168.40.141 cicd-gitlab
安装gitlab依赖包
[root@cicd-gitlab ~]# yum install -y curl openssh-server openssh-clients postfix cronie policycoreutils-python
开启邮件服务
[root@cicd-gitlab ~]# systemctl start postfix
[root@cicd-gitlab ~]# systemctl enable postfix
添加gitlab安装源
阿里源
[root@cicd-gitlab ~]# vim /etc/yum.repos.d/gitlab-ce.repo
[gitlab-ce]
name=gitlab-ce
baseurl=http://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el7
Repo_gpgcheck=0
Enabled=1
gpgcheck=0
清华源:
[root@cicd-gitlab ~]# vim gitlab-ce.repo
[gitlab-ce]
name=Gitlab CE Repository
baseurl=https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el$releasever/
gpgcheck=0
enabled=1
[root@cicd-gitlab ~]# vim gitlab-ee.repo
[gitlab-ee]
name&