首页服务器Centos7五步搭建Gitlab环境 想用Gitlab管理项目?你先看看这篇文章

Centos7五步搭建Gitlab环境 想用Gitlab管理项目?你先看看这篇文章

时间2024-03-21 19:32:02发布访客分类服务器浏览1434
导读:这篇文章给大家介绍了“Centos7五步搭建Gitlab环境 想用Gitlab管理项目?你先看看这篇文章”的相关知识,讲解详细,步骤过程清晰,对大家进一步学习和理解“Centos7五步搭建Gitlab环境 想用Gitlab管理项目?你先看看...
这篇文章给大家介绍了“Centos7五步搭建Gitlab环境 想用Gitlab管理项目?你先看看这篇文章”的相关知识,讲解详细,步骤过程清晰,对大家进一步学习和理解“Centos7五步搭建Gitlab环境 想用Gitlab管理项目?你先看看这篇文章”有一定的帮助,希望大家阅读完这篇文章能有所收获。下面就请大家跟着小编的思路一起来学习一下吧。

 


1.准备一台Centos7环境。
如果是Window环境参考以下博客:

[WINDOWS7五步快速搭建Centos7环境](https://blog.csdn.net/doegoo/article/details/80061524)

2.安装前准备

参考官方文档:
[https://about.gitlab.com/installation/#centos-7]
安装相关工具类:
sudo yum install -y curl policycoreutils-python openssh-server
sudo systemctl enable sshd
sudo systemctl start sshd
sudo firewall-cmd --permanent --add-service=http
sudo systemctl reload firewalld

sudo yum install postfix
sudo systemctl enable postfix
sudo systemctl start postfix

3.配置国内YUM源

参考清华源:
[清华源官网](https://mirror.tuna.tsinghua.edu.cn/help/gitlab-ce/)
执行以下命令:
新建 /etc/yum.repos.d/gitlab-ce.repo,内容为
[gitlab-ce]
name=Gitlab CE Repository
baseurl=https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el$releasever/
gpgcheck=0
enabled=1

执行命令:
sudo yum makecache
sudo yum install gitlab-ce

4.安装gitlab-ce

sudo EXTERNAL_URL="http://gitlab.自已的域名.com" yum install -y gitlab-ee
或者:
sudo yum install -y gitlab-ee

5.启动gitlab-ce

sudo gitlab-ctl reconfigure
可使用 sudo vim /etc/gitlab/gitlab.rb 修改配置在执行以上命令重新加载
sudo gitlab-ctl status查看状态 出现在以下状态安装成功:
[vagrant@localhost ~]$ sudo gitlab-ctl status
run: gitaly: (pid 593) 1377s;
     run: log: (pid 592) 1377s
run: gitlab-monitor: (pid 611) 1377s;
     run: log: (pid 602) 1377s
run: gitlab-workhorse: (pid 610) 1377s;
     run: log: (pid 599) 1377s
run: logrotate: (pid 609) 1377s;
     run: log: (pid 591) 1377s
run: nginx: (pid 607) 1377s;
     run: log: (pid 594) 1377s
run: node-exporter: (pid 601) 1377s;
     run: log: (pid 600) 1377s
run: postgres-exporter: (pid 587) 1377s;
     run: log: (pid 586) 1377s
run: postgresql: (pid 589) 1377s;
     run: log: (pid 588) 1377s
run: prometheus: (pid 606) 1377s;
     run: log: (pid 605) 1377s
run: redis: (pid 608) 1377s;
     run: log: (pid 590) 1377s
run: redis-exporter: (pid 583) 1377s;
     run: log: (pid 582) 1377s
run: sidekiq: (pid 585) 1377s;
     run: log: (pid 584) 1377s
run: unicorn: (pid 604) 1377s;
     run: log: (pid 603) 1377s

通过以上内容的阐述,相信大家对“Centos7五步搭建Gitlab环境 想用Gitlab管理项目?你先看看这篇文章”已经有了进一步的了解,更多相关的问题,欢迎关注网络或到官网咨询客服。

声明:本文内容由网友自发贡献,本站不承担相应法律责任。对本内容有异议或投诉,请联系2913721942#qq.com核实处理,我们将尽快回复您,谢谢合作!


若转载请注明出处: Centos7五步搭建Gitlab环境 想用Gitlab管理项目?你先看看这篇文章
本文地址: https://pptw.com/jishu/649485.html
nginx配置访问认证提高安全性 CentOS下用chkconfig管理配置nginx

游客 回复需填写必要信息