centos8 gitlab 安装

2023-01-10  本文已影响0人  程序猿小伙子

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

systemctl enable postfix

systemctl start postfix

5,下载gitlab

wget https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el8/gitlab-ce-12.10.1-ce.0.el8.x86_64.rpm

6,安装

rpm -ivh gitlab-ce-10.0.0-ce.0.el7.x86_64.rpm

成功如图:

7、编辑ip和端口

vim /etc/gitlab/gitlab.rb

gitlab-ctl reconfigure

gitlab-ctl restart

8,访问gitlab ip+端口

如果输入端口和ip一直无法响应,可以关闭防火墙

systemctl stop firewalld

如果访问502,查看

https://www.cnblogs.com/stronger-xsw/p/12804002.html

重新配置并启动

gitlab-ctl reconfigure

gitlab-ctl restart

开启:

gitlab-ctl start

关闭:

gitlab-ctl stop

9,成功如图:

10,第一次登录需要修改root密码, 密码8位以上,修改完就可以登录使用设置的新密码,登录

其他操作类似添加账号,仓库等等自己百度

上一篇 下一篇

猜你喜欢

热点阅读