Gitlab
2022年8月24日大约 2 分钟
Gitlab
配置 access_token 使用 https clone 仓库
git - Using GitLab token to clone without authentication - Stack Overflow
Personal access tokens | GitLab
执行Git命令时出现各种 SSL certificate problem 的解决办法_officercat的博客-CSDN博客
打开 Gitlab->偏好设置->访问令牌 配置一个权限全开的令牌, 点击 创建个人访问令牌 后会出现一个访问令牌字符串, 记录下该字符串, 本文之后将该字符串称为 access_token


在本地添加一条 git 配置, 取消 ssl 验证
git config --global http.sslVerify false然后即可使用 https + access_token clone 仓库了
git clone https://oauth2:[access_token]@gitlab.xxx.com/xxxx.git其实就是在仓库的 https clone 链接中的
https://后加上oauth2:[access_token]再把后面的链接拼接上即可
Gitlab 搭建(想了想不想维护, 就没再搭了)
配置参考
创建工作目录
# 创建 gitlab 工作目录
mkdir xxx
cd xxx安装 docker 并拉取官方镜像
安装所需工具包
sudo apt-get install apt-transport-https ca-certificates curl gnupg-agent software-properties-common更新现有的软件包列表
sudo apt-get update然后将官方 Docker 版本库的 GPG 密钥添加到系统中:
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -将 Docker 版本库添加到APT源:
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu focal stable"用新添加的 Docker 软件包来进行升级更新。
sudo apt update确保要从 Docker 版本库,而不是默认的 Ubuntu 版本库进行安装:
apt-cache policy docker-ce安装 Docker :
sudo apt install docker-ce现在 Docker 已经安装完毕。我们启动守护程序。检查 Docker 是否正在运行:
sudo systemctl status docker系统方面支持