使用Docke注册Runner
2023-12-14 17:53:20
获取你的token
## 启动docker
docker run -d --name gitlab-runner \
--restart always \
-v /var/run/docker.sock:/var/run/docker.sock \
-v /srv/gitlab-runner/config:/etc/gitlab-runner \
gitlab/gitlab-runner:alpine-v16.2.3
进入容器
# docker exec -it gitlab-runner bash
# gitlab-runner register
http://gitlab.neway.com
Enter the registration token:
NJrUkircTGxTzPtQfZUz -------------
Enter a description for the runner:
[2af202bf1943]: uat-config -------------
Enter tags for the runner (comma-separated):
uat,prod ---------------
Enter optional maintenance note for the runner:
uat-config -----------
WARNING: Support for registration tokens and runner parameters in the 'register' command has been deprecated in GitLab Runner 15.6 and will be replaced with support for authentication tokens. For more information, see https://gitlab.com/gitlab-org/gitlab/-/issues/380872
Registering runner... succeeded runner=NJrUkirc
Enter an executor: virtualbox, docker-autoscaler, docker+machine, instance, custom, docker, parallels, ssh, kubernetes, docker-windows, shell:
docker ------------
Enter the default Docker image (for example, ruby:2.7):
docker:20.10.16 ------------
Runner registered successfully. Feel free to start it, but if it's running already the config should be automatically reloaded!
Configuration (with the authentication token) was saved in "/etc/gitlab-runner/config.toml"
文章来源:https://blog.csdn.net/weixin_42562106/article/details/134997502
本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。 如若内容造成侵权/违法违规/事实不符,请联系我的编程经验分享网邮箱:veading@qq.com进行投诉反馈,一经查实,立即删除!
本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。 如若内容造成侵权/违法违规/事实不符,请联系我的编程经验分享网邮箱:veading@qq.com进行投诉反馈,一经查实,立即删除!