网站运维:git工具(10):GitLab安装和使用

本文详细介绍GitLab的安装步骤及配置方法,包括依赖关系安装、邮件服务器设置、防火墙及SELinux管理、软件包下载与安装、启动及账户密码说明。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

GitLab英文官网
https://about.gitlab.com/
GitLab中文官网
https://www.gitlab.com.cn
GitLab使用手册
https://docs.gitlab.com.cn/ce/README.html
查看GitLab硬件需求
https://docs.gitlab.com.cn/ce/install/requirements.html


GitLab安装和使用
安装并配置GitLab必要的依赖关系
yum -y install curl openssh-server openssh-clients postfix cronie policycoreutils-python

启动邮件服务器postfix
service postfix start

避免用户通过ssh方式和http来访问
lokkit -s http -s ssh
下载GitLab软件包
https://packages.gitlab.com/gitlab/gitlab-ce/packages/el/6/gitlab-ce-11.1.4-ce.0.el6.x86_64.rpm
或
https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el6/
安装GitLab软件包
rpm -vih gitlab-ce-11.1.4-ce.0.el6.x86_64.rpm --force --nodeps

启动GitLab
gitlab-ctl reconfigure

永久性关闭防火墙
chkconfig iptables off

临时性关闭防火墙
service iptables stop

永久性关闭selinux
修改 /etc/selinux/config 文件中的 SELINUX="disabled"


即时生效
setenforce 0

GitLab默认账号和密码
Username: root
Password: 5iveL!Fe

GitLab配置文件
vim /etc/gitlab/gitlab.rb 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值