Ubuntu上安装配置gitlab

本文只用于自己记录安装过程,方便日后自己使用

一. 安装

安装参考:

https://blog.csdn.net/qq_43279457/article/details/126295413
注: 安装过程中参考有错误的地方
第四点:设置Ubuntu网络中是

127.0.0.1 mygitlab.com

汉化参考:
https://zhuanlan.zhihu.com/p/340093022

需要汉化就要下载对应的gitlab版本。包括原先的英语版本和汉化需要对应起来。

二. 卸载gitlab

参考链接
https://blog.csdn.net/YiLiuF/article/details/104580979/

三. 我的安装步骤
1. 安装和配置依赖
sudo apt-get update

sudo apt-get install -y curl openssh-server ca-certificates tzdata

sudo apt-get install -y postfix

systemctl enable postfix
2. 安装软件包
curl -sS https://packages.gitlab.com/install/repositories/gitlab/gitlab-ce/script.deb.sh | sudo bash

sudo apt-get install gitlab-ce

如果安装不成功就参考https://zhuanlan.zhihu.com/p/340093022 中下载安装包进行安装。

3. 配置和使用
修改域名和端口

sudo vim /etc/gitlab/gitlab.rb

gitlab.rb 文件中修改成

在这里插入图片描述

4. 初始化gitlab
sudo gitlab-ctl reconfigure

敲完命令后会一直刷屏,你需要等一会儿时间

5. 配置Ubuntu网络
sudo vim /etc/hosts

添加设置成如下内容

127.0.0.1 mygitlab.com

添加完成后重启ubuntu

6.配置winuows hosts

查看ubuntu ip
在这里插入图片描述

编辑Windows的C:\Windows\System32\drivers\etc\hosts文件

增加

192.168.126.128 mygitlab.com

7.通过网页访问

网页访问 http://mygitlab.com:8088/
默认用户名:root
默认密码:*********
默认密码存储位置

sudo vim /etc/gitlab/initial_root_password
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值