yum install https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el7/gitlab-ce-10.3.4-ce.0.el7.x86_64.rpm
修改gitlab配置文件指定服务器ip和自定义端口:
cat /etc/gitlab/gitlab.rb |grep -v ^$|grep -v ^#
external_url 'http://192.168.0.246:7023'git_data_dirs({"default" => {"path" => "/home/git-data"}})gitlab_rails['smtp_enable'] = truegitlab_rails['smtp_address'] = "smtp.exmail.qq.com"gitlab_rails['smtp_port'] = 25gitlab_rails['smtp_user_name'] = "lcn@gdhmit.com"gitlab_rails['smtp_password'] = "Asdf2017"gitlab_rails['smtp_domain'] = "smtp.qq.com"gitlab_rails['smtp_authentication'] = "login"gitlab_rails['smtp_enable_starttls_auto'] = falsegitlab_rails['smtp_tls'] = false
mkdir /home/git-datachown -R git:git /home/git-datagitlab-ctl reconfiguregitlab-ctl restart
提示 "ok: run:"表示启动成功
访问 GitLab页面
http://192.168.0.246:7023