Chinaunix首页 | 论坛 | 博客
  • 博客访问: 932645
  • 博文数量: 481
  • 博客积分: 0
  • 博客等级: 民兵
  • 技术积分: 5078
  • 用 户 组: 普通用户
  • 注册时间: 2018-03-07 14:48
个人简介

分享工作和学习中的点点滴滴,包括前端、后端、运维、产品等各个方面,欢迎您来关注订阅!

文章分类

全部博文(481)

文章存档

2023年(26)

2022年(97)

2021年(119)

2020年(153)

2019年(70)

2018年(16)

我的朋友

分类: LINUX

2021-02-25 14:35:50

GitLab是一个基于web界面的Git仓库管理程序,包括代码审计、wikis、问题跟踪等功能。使用GitLab创建、检查和部署代码非常容易。它可以托管在我们自己的服务器上,在官方服务器也提供免费的仓库托管,类似于Github。

GitLab有三个不同的版本可用:Community Edition(CE)、Enterprise Edition(EE)和 GitLab托管版本。其中CE版本是开源免费的。EE版本是企业版,需要付费使用的。

环境
  • 8
  • gitlab-ce-13.1.4

推荐cpu核心数量为4核,推荐内存大小为4GB。

安装GitLab-CE

新建/etc/yum.repos.d/gitlab-ce.repo仓库文件,然后复制内容到文件里。

[root@localhost ~]# touch /etc/yum.repos.d/gitlab-ce.repo 

[gitlab-ce] name=Gitlab CE Repository baseurl= gpgcheck=0 enabled=1

如何在Centos8中安装GitLab-CE如何在Centos8中安装GitLab-CE
更新yum缓存,然后安装gitlab-ce:

[root@localhost ~]# yum makecache
[root@localhost ~]# yum -y install gitlab-ce

如何在Centos8中安装GitLab-CE如何在Centos8中安装GitLab-CE
安装完成。

防火墙中开放端口
[root@localhost ~]# firewall-cmd --permanent --add-service=http
success
[root@localhost ~]# firewall-cmd --permanent --add-service=https
success
[root@localhost ~]# firewall-cmd --reload
success
配置并启动gitlab

刚安装完,需要配置一下gitlab。

[root@localhost ~]# gitlab-ctl reconfigure

配置完成之后已经启动所有服务了,已经设置好开机启动了。

gitlab-ctl的常用的操作:

# 重置应用
gitlab-ctl reconfigure
# 启动所有服务
gitlab-ctl start
# 关闭所有服务
gitlab-ctl stop
# 重启所有服务
gitlab-ctl restart
# 列出所有服务
gitlab-ctl service-list
# 查看服务状态
gitlab-ctl status
web界面访问GitLab

在浏览器输入本机ip地址,访问gitlab,第一次访问需要为管理员设置密码:
如何在Centos8中安装GitLab-CE如何在Centos8中安装GitLab-CE
默认的用户是root,刚设置好密码,可以登录了:
如何在Centos8中安装GitLab-CE如何在Centos8中安装GitLab-CE

如何在Centos8中安装GitLab-CE如何在Centos8中安装GitLab-CE
然后就可以创建project了。
如何在Centos8中安装GitLab-CE如何在Centos8中安装GitLab-CE

总结

GitLab能够集成大量的工具,如Slack、Hipchat、LDAP、JIRA、Jenkins、许多类型的钩子和一个完整的API。

阅读(1326) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~