【运维笔记】gitlab

Gitlab安装

gitlab-ce(社区版)		gitlab-ee(企业版)
yum install audit-libs-python checkpolicy libcgroup libsemanage-python policycoreutils-python python-IPy setools-libs
1、配置yum源
	vim /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

2、更新本地yum缓存
	yum makecache

3、安装GitLab社区版
	yum install gitlab-ce        #自动安装最新版
	yum install gitlab-ce-x.x.x    #安装指定版本

4、	vim /etc/gitlab/gitlab.rb		#修改默认的配置文件;
	external_url更改为自己服务器

5、启动服务
	gitlab-ctl reconfigure

6、启动所有组件
	gitlab-ctl start

7、首次登陆设置密码

gitlab常用命令

gitlab-ctl reconfigure        #启动服务,自动配置文件权限,安装数据库(安装的时间很长)
gitlab-ctl start    			# 启动所有 gitlab 组件;
gitlab-ctl stop       			# 停止所有 gitlab 组件;
gitlab-ctl restart        		# 重启所有 gitlab 组件;
gitlab-ctl status        		# 查看服务状态;
gitlab-ctl tail       			 # 查看日志



gitlab-rake gitlab:check SANITIZE=true --trace    # 检查gitlab;

GitLab管理

1、添加用户,上传ssh key
2、创建用户组
3、将用户添加到用户组,分配权限
4、创建项目

猜你喜欢

转载自blog.csdn.net/wuguifa/article/details/88327348
今日推荐