gitlab安装升级,以及报错解决(查看的官方文档以及网上信息)

gitlab安装

下载rpm包
13.3.6rpm

cd /opt/module 把安裝包放入此文件夹

vim gitlab-install.sh 添加脚本文件,并把下面代码放入脚本:

sudo rpm -ivh /opt/module/gitlab-ce-13.3.6-ce.0.el7.x86_64.rpm
sudo yum install -y curl policycoreutils-python openssh-server cronie
sudo lokkit -s http -s ssh
sudo yum install -y postfix
sudo service postfix start
sudo chkconfig postfix on
curl https://packages.gitlab.com/install/repositories/gitlab/gitlab-ce/script.rpm.sh | sudo bash
sudo EXTERNAL_URL="http://gitlab.example.com" yum -y install gitlab-ce
chmod +x gitlab-install.sh

运行

查看版本

cat /opt/gitlab/embedded/service/gitlab-rails/VERSION

​ 执行以下命令初始化 GitLab 服务,过程大概需要几分钟.

gitlab-ctl reconfigure

启动

gitlab-ctl start  

账号:root
密码:redhat123
禁止 Gitlab 开机自启动:
systemctl disable gitlab-runsvdir.service

启用 Gitlab 开机自启动:
enable gitlab-runsvdir.service

备份升级

备份:

gitlab-backup create

默认位置

# gitlab_rails['backup_path'] = "/var/opt/gitlab/backups"

/var/opt/gitlab/gitlab-rails/shared/pages

官方包升级:

RHEL/CentOS 6 and 7
sudo yum install gitlab-ce

特定包升级

RHEL/CentOS 6 and 7
yum --showduplicates list gitlab-ce

RHEL/CentOS 6 and 7
yum install gitlab-ce-<version>
yum install gitlab-ce-13.12.15-ce.0.el7

报错记录

GitLab external URL must include a schema and FQDN

解决办法
vi /etc/gitlab/gitlab.rb
将
external_url 'xxx'
改成
external_url= 'xxx'
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值