首页 > 其他 > 详细

gitlab-runner安装

时间:2018-10-11 16:42:57      阅读:259      评论:0      收藏:0      [点我收藏+]
一、添加yum源

curl -L https://packages.gitlab.com/install/repositories/runner/gitlab-runner/script.rpm.sh | sudo bash

二、安装gitlab-runner

yum install gitlab-runner -y

三、配置gitlab-runner

向GitLab-CI注册一个Runner需要两样东西:GitLab-CI的url和注册token。
其中,token是为了确定你这个Runner是所有工程都能够使用的Shared Runner还是具体某一个工程才能使用的Specific Runner。

如果要注册Shared Runner,你需要到管理界面的Runners页面里面去找注册token。

[root@dx-cdh3 cmdb]# gitlab-runner register
Running in system-mode.                            

Please enter the gitlab-ci coordinator URL (e.g. https://gitlab.com/):
http://gitlab.clife.cn/
Please enter the gitlab-ci token for this runner:
jmGuf9k2WsssNaxsBGcnJ6T
Please enter the gitlab-ci description for this runner:
[dx-cdh3]: share_runner
Please enter the gitlab-ci tags for this runner (comma separated):

Registering runner... succeeded                     runner=jmGuf9k2
Please enter the executor: shell, virtualbox, docker+machine, docker-ssh+machine, kubernetes, docker, docker-ssh, parallels, ssh:
shell
Runner registered successfully. Feel free to start it, but if it‘s running already the config should be automatically reloaded! 

四、如果需要使用docker构建服务跟发布,添加用户到docker用户组

usermod -a -G docker gitlab-runner

gitlab-runner安装

原文:http://blog.51cto.com/aaronsa/2298740

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!