1.安装依赖包 sudo yum install -y curl policycoreutils-python openssh-server cronie
2.使用清华大学开源软件镜像源安装 vim /etc/yum.repos.d/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
3.更新本地YUM缓存
yum makecache
4.自动安装最新版本
yum install gitlab-ce
5.修改配置文件/etc/gitlab/gitlab.rb,绑定域名
vim /etc/gitlab/gitlab.rb
external_url 'http://gitlab.zouke.com'
6.启动GitLab,使得配置生效
gitlab-ctl reconfigure
7.访问gitlab
gitlab安装参考博文: