gitlab的安装

1、下载rpm 安装包

(1)直接命令下载

bash 复制代码
wget https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el7/gitlab-ce-11.6.10-ce.0.el7.x86_64.rpm

(2)直接去服务器上下载包

Index of /gitlab-ce/yum/el7/ | 清华大学开源软件镜像站 | Tsinghua Open Source Mirror

2、文件提权

bash 复制代码
chmod 777 gitlab-ce-11.6.10-ce.0.el7.x86_64.rpm

3、安装

bash 复制代码
rpm -ivh gitlab-ce-11.6.10-ce.0.el7.x86_64.rpm

4、更改环境配置

打开配置文件修改external_url。改成自己机器的地址和端口号

bash 复制代码
vim /etc/gitlab/gitlab.rb

启动服务

bash 复制代码
#(每次修改完gitlab.rb文件需要执行该操作)
gitlab-ctl reconfigure
gitlab-ctl restart
gitlab-ctl status

5、查看root 的密码

bash 复制代码
vim /etc/gitlab/initial_root_password

6、登录查看

7、修改默认密码

bash 复制代码
  $ gitlab-rails console -e production
  irb> user = User.find_by(username: 'root')
  irb> user.password = 'password'
  irb> user.password_confirmation = 'password'
  irb> user.save!
  irb> exit

重启服务

bash 复制代码
gitlab-ctl restart

8、关闭防火墙

bash 复制代码
systemctl stop firewalld.service

9、永久关闭防火墙

bash 复制代码
systemctl disable firewalld.service
相关推荐
轻松Ai享生活2 分钟前
揭秘 linux:一张图看懂系统配置的核心
linux
wdxylb11 分钟前
云原生俱乐部-RH134知识点总结(2)
linux·云原生
_Chipen19 分钟前
lazy_vim_cmake_clangd_从零到自动补全与语法检查
linux·编辑器·vim
椰子今天很可爱1 小时前
静态库和动态库
linux
檀越剑指大厂2 小时前
【Linux系列】如何在 Linux 服务器上快速获取公网
linux·服务器·php
共享家95272 小时前
linux-高级IO(上)
java·linux·服务器
HWL56793 小时前
“preinstall“: “npx only-allow pnpm“
运维·服务器·前端·javascript·vue.js
小米里的大麦5 小时前
022 基础 IO —— 文件
linux
Xの哲學5 小时前
Perf使用详解
linux·网络·网络协议·算法·架构
门前灯5 小时前
Linux系统之iprconfig 命令详解
linux·运维·服务器·iprconfig