CICD 持续集成与持续交付——gitlab

部署

虚拟机最小需求:4G内存 4核cpu

下载:https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el7/

安装依赖性

复制代码
[root@cicd1 ~]# yum install -y curl policycoreutils-python openssh-server perl

[root@cicd1 ~]# yum install -y gitlab-ce-15.9.3-ce.0.el7.x86_64.rpm

[root@cicd1 ~]# cd /etc/gitlab/

[root@cicd1 gitlab]# vim gitlab.rb

自动化部署

复制代码
[root@cicd1 gitlab]# gitlab-ctl reconfigure
复制代码
[root@cicd1 ~]# gitlab-ctl status

登录

用户:root

初始密码: cat /etc/gitlab/initial_root_password

语言设置

修改密码,初始密码24小时后过期

新建项目

添加密钥

克隆项目

复制代码
[root@cicd1 ~]# git clone git@192.168.92.21:root/demo.git

[root@cicd1 ~]# cd demo/

[root@cicd1 demo]# ls

[root@cicd1 demo]# git remote -v
复制代码
[root@cicd1 demo]# echo www.westos.org > index.html

[root@cicd1 demo]# ls

[root@cicd1 demo]# git add  index.html

[root@cicd1 demo]# git commit -m "add index.html"

[root@cicd1 demo]# git push -u origin main
相关推荐
3Cloudream8 小时前
互联网大厂Java面试深度解析:从基础到微服务云原生的全场景模拟
java·spring boot·redis·elasticsearch·微服务·kafka·电商架构
streaker30311 小时前
GitLab CI/CD 中实现前端增量 Lint(ESLint & Stylelint)实践
ci/cd·gitlab
Elasticsearch13 小时前
将 agents 连接到 Elasticsearch 使用模型上下文协议 - docker
elasticsearch
_風箏13 小时前
SpringBoot【ElasticSearch集成 02】Java HTTP Rest client for ElasticSearch Jest 客户端集成
java·后端·elasticsearch
柯南二号14 小时前
【开发配置】GitLab CR(Code Review)规则配置清单
gitlab·代码复审
柯南二号14 小时前
【开发配置】云服务器配置Gitlab服务
运维·服务器·gitlab
坐吃山猪15 小时前
ES03-常用API
elasticsearch·es
Elasticsearch18 小时前
探索 Vertex AI 与 Elasticsearch
elasticsearch
DevOps_node19 小时前
docker-compose部署gitlab
gitlab·linux基础设施·linux中间件
半路程序员1 天前
Mac安装docker,启动elasticsearch
elasticsearch·docker·容器