gitlab ci失败与自定义运行器 [英] gitlab ci failing with custom runner
问题描述
我正尝试创建一个自定义gitlab-runner来运行docker进程,如下所示:
I'm trying to create a custom gitlab-runner to run a docker process, following:
https://github.com/gitlabhq /gitlabhq/blob/master/doc/ci/docker/using_docker_build.md
我尝试了使用以下方法注册跑步者的第二种方法:
I tried the second approach in which I registered a runner using:
sudo gitlab-runner注册-n \ --url https://gitlab.com/ \
--registration-token xxx \ --executor docker \ --description我的Docker Runner" \ --docker-image"docker:stable" \ --docker-volumes /var/run/docker.sock:/var/run/docker.sock
sudo gitlab-runner register -n \ --url https://gitlab.com/ \
--registration-token xxx \ --executor docker \ --description "My Docker Runner" \ --docker-image "docker:stable" \ --docker-volumes /var/run/docker.sock:/var/run/docker.sock
但是,在gitlab上,每当管道启动时,我都会遇到以下错误:
However,at gitlab, whenever the pipeline starts I'm facing the following error:
错误:无法为/builds/xxx创建容器卷,无法执行 加载图片:gitlab-runner-prebuilt:打开 /var/lib/gitlab-runner/gitlab-runner-prebuilt.tar.xz:无此类文件或 目录"
ERROR: Failed to create container volume for /builds/xxx Unable to load image: gitlab-runner-prebuilt: "open /var/lib/gitlab-runner/gitlab-runner-prebuilt.tar.xz: no such file or directory"
我在网上找不到太多信息,不胜感激.
I can't find much information online, any help appreciated.
推荐答案
对于记录,我可以按照本教程进行操作
For The record, I got it working following this tutorial
https://angristan.xyz/build-push-docker- images-gitlab-ci/
由于docker映像正常工作,我怀疑debian gitlab-runner发行版有问题
Since the docker image worked, I suspect there's something wrong with the debian gitlab-runner distribution
这篇关于gitlab ci失败与自定义运行器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!