centos8.5安装使用学习gitlab14.6

首先,系统是 CentOS-8.5.2111-x86_64-dvd1.iso

gitlab版本是:gitlab-ce-14.6.2-ce.0.el8.x86_64.rpm

安装步骤参照:https://www.cnblogs.com/stronger-xsw/p/12802069.html

具体内容如下,直接复制了啊:

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 -i 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位以上,修改完就可以登录
使用设置的新密码,登录

开始使用:

1、新建了个用户feiye,用feiye登录后,新建了组front-edge,然后在这个组下建了个项目VueLearn,但是呢,发现默认分支名称不是master,而是main,,,这不行啊,不习惯啊,,得改

 首先新建一个分支叫master,然后 进入到当前项目的 "project settings",Settings-->Repository-->Default branch-->Expand,然后选择新创建的master分支,然后 保存,此时默认分支已经是master了,然后给master分支设置保护。

 

posted @ 2022-01-19 23:58  飞叶-枯寂  阅读(571)  评论(0编辑  收藏  举报