1,安装依赖
yum install -y curl policycoreutils-python openssh-server
centos8没有policycoreutils-python yum源,不用管
2,启动ssh并设置为开机自启动
systemctl enable sshd
systemctl start sshd
3,添加http服务到firewalld,pemmanent表示永久生效,若不加–permanent系统下次启动后就会失效
systemctl start firewalld
firewall-cmd --permanent --add-service=http
systemctl reload firewalld
4.接下来,安装Postfix以发送通知邮件,安装命令:
sudo yum install postfix
5,启动postfix
systemctl enable postfix
systemctl start postfix
5,下载gitlab
wget https://mirrors.tuna.tsinghua.edu.cn/gitlab-ee/yum/el6/gitlab-ee-13.0.0-ee.0.el6.x86_64.rpm
6,安装
rpm -i gitlab-ee-13.0.0-ee.0.el6.x86_64.rpm
成功如图:
7.阿里云CENTOS8有可能会报错
只需要在rpm -i gitlab-ee-13.0.0-ee.0.el6.x86_64.rpm 加上 --nodeps --force
成功如图:
8.12.安装vim编辑器 安装命令:
yum install vim -y
9,编辑ip和端口
vim /etc/gitlab/gitlab.rb
进入编辑器后按“i”键进入编辑状态,ESC键退出编辑状态
退出并保存,命令输入“:wq
external_url地址修改成“”“https://服务器公网ip:端口号”。有自己域名的话可以吧公网IP改成自己的域名,已经备过案的域名.。
10.重启服务:
gitlab-ctl reconfigure
gitlab-ctl restart
11.成功如下:
12.访问gitlab ip+端口
如果输入端口和ip一直无法响应,可以关闭防火墙
sudo systemctl stop firewalld
13,第一次登录需要修改root密码, 密码8位以上,修改完就可以登录
使用设置的新密码,登录
-----------------如需转载请注明出处,原创版权所有