GitLab CI / CD-在我自己的主机上使用Runner时管道阻塞

时间:2019-06-23 20:32:12

标签: gitlab gitlab-ci-runner

我已经在GitLab上为我的玩具项目设置了CI / CD。将Runner 安装在自己的主机上并为我的项目激活后,我通过以下方式仔细检查了所有内容:

  1. 运行gitlab-runner verify并获得结果

enter image description here

  1. 在GitLab上,完成注册步骤(gitlab-runner register)后我得到了结果

enter image description here

GiLab Runner的config文件中的内容如下

concurrent = 1
check_interval = 0

[session_server]
  session_timeout = 1800

[[runners]]
  name = "localhost"
  url = "https://gitlab.com/"
  token = MyTokenProvidedByGitLab
  executor = "ssh"
  [runners.custom_build_dir]
  [runners.ssh]
    user = "root"
    host = "MyHost.org"
    port = "22"
    identity_file = "/d/ssh/id_rsa"
  [runners.cache]
    [runners.cache.s3]
    [runners.cache.gcs]

但是,管道卡住了

enter image description here

此外,我还执行了命令gitlab-runner run来尝试使管道运行,但似乎不起作用,下面是图片

enter image description here

设置步骤有什么问题吗?

1 个答案:

答案 0 :(得分:1)

您需要启动gitlab Runner服务流程

首先测试转轮是否已正确安装 在您的存储库目录

运行

gitlab-runner exec shell <Job-Name>

如果您的项目运行正常,则

我的猜测是,如果我们按阶段按钮  我们看到没有任何人可以胜任这份工作

打开命令行并在包含.gitlab.yml的项目目录中运行( )

gitlab-runner.exe run

然后,如果启动该任务,则在启动时将此命令作为服务添加到主机上

相关问题