当前位置: 代码迷 >> 综合 >> 国内centos7服务下快速安装 gitlab-runner
  详细解决方案

国内centos7服务下快速安装 gitlab-runner

热度:16   发布时间:2023-12-12 09:25:09.0

安装

1.添加yum源curl -L https://packages.gitlab.com/install/repositories/runner/gitlab-ci-multi-runner/script.rpm.sh | sudo bash
2.安装runneryum install gitlab-ci-multi-runner
3.向GitLab-CI注册runnergitlab-ci-multi-runner register

说明:

注册需要:GitLab-CI的url和注册token
位置在项目的setting里面(位置和名字不同的gitlab版本可能有差异)
在这里插入图片描述
注册时是会有提示

b.Enter your GitLab instance URL:
Please enter the gitlab-ci coordinator URL (e.g. https://gitlab.com )你的gitlab地址
c.Enter the token you obtained to register the Runner:
Please enter the gitlab-ci token for this runner你的token
d.Enter a description for the Runner, you can change this later in GitLab's UI: Please enter the gitlab-ci description for this runner [hostame] my-runner e.Enter the tags associated with the Runner, you can change this later in GitLab's UI:
Please enter the gitlab-ci tags for this runner (comma separated):tag 可以不写
f.Enter the Runner executor:
Please enter the executor: ssh, docker+machine, docker-ssh+machine, kubernetes, docker, parallels, virtualbox, docker-ssh, shell:shell