跑步者不健康,将被禁用

时间:2019-03-16 07:30:31

标签: linux gitlab gitlab-ci gitlab-ci-runner

我用gitlab.com托管我的存储库,并在runner中安装了DigitalOcean。一直运行到今天泰国时间16March2019 14:24

# gitlab-runner status
Runtime platform                                    arch=amd64 os=linux pid=16937 revision=4745a6f3 version=11.8.0
gitlab-runner: Service is running!
# gitlab-runner unregister --all-runners
Runtime platform                                    arch=amd64 os=linux pid=16299 revision=4745a6f3 version=11.8.0
Running in system-mode.

WARNING: Unregistering all runners
ERROR: Unregistering runner from GitLab forbidden   runner=2bcd7af4
ERROR: Failed to unregister runner HerrRunner
# gitlab-runner list
Runtime platform                                    arch=amd64 os=linux pid=16346 revision=4745a6f3 version=11.8.0
Listing configured runners                          ConfigFile=/etc/gitlab-runner/config.toml
HerrRunner                                          Executor=shell Token=2bcd7af455f866ede7991992a68780 URL=https://gitlab.com/
# gitlab-runner --debug run
Runtime platform                                    arch=amd64 os=linux pid=16395 revision=4745a6f3 version=11.8.0
Starting multi-runner from /etc/gitlab-runner/config.toml ...  builds=0
Checking runtime mode                               GOOS=linux uid=0
Running in system-mode.

Configuration loaded                                builds=0
listenaddress: ""
sessionserver:
  listenaddress: ""
  advertiseaddress: ""
  sessiontimeout: 1800
metricsserveraddress: ""
concurrent: 1
checkinterval: 0
loglevel: null
logformat: null
user: ""
runners:
- name: HerrRunner
  limit: 0
  outputlimit: 0
  requestconcurrency: 0
  runnercredentials:
    url: https://gitlab.com/
    token: 2bcd7af455f866ede7991992a68780
    tlscafile: ""
    tlscertfile: ""
    tlskeyfile: ""
  runnersettings:
    executor: shell
    buildsdir: ""
    cachedir: ""
    cloneurl: ""
    environment: []
    preclonescript: ""
    prebuildscript: ""
    postbuildscript: ""
    shell: ""
    ssh: null
    docker: null
    parallels: null
    virtualbox: null
    cache:
      type: ""
      path: ""
      shared: false
      s3: null
      gcs: null
      s3cachepath: ""
      cacheshared: false
      serveraddress: ""
      accesskey: ""
      secretkey: ""
      bucketname: ""
      bucketlocation: ""
      insecure: false
    machine: null
    kubernetes: null
sentrydsn: null
modtime: 2018-08-12T18:07:07.963445119Z
loaded: true
  builds=0
Waiting for stop signal                             builds=0
Listen address not defined, metrics server disabled  builds=0
Listen address not defined, session server disabled  builds=0
Starting worker                                     builds=0 worker=0
Feeding runners to channel                          builds=0
Dialing: tcp gitlab.com:443 ...
ERROR: Checking for jobs... forbidden               runner=2bcd7af4
Feeding runners to channel                          builds=0
ERROR: Checking for jobs... forbidden               runner=2bcd7af4
Feeding runners to channel                          builds=0
ERROR: Checking for jobs... forbidden               runner=2bcd7af4
ERROR: Runner https://gitlab.com/2bcd7af455f866ede7991992a68780 is not healthy and will be disabled!
Feeding runners to channel                          builds=0
Feeding runners to channel                          builds=0
Feeding runners to channel                          builds=0
^CWARNING: Requested service stop: interrupt          builds=0
All workers stopped. Can exit now                   builds=0

最终目标

让我的跑步者起来并再次跑步

问题:

  1. not healthy是什么意思?

  2. 我无法注销跑步者。如何解决这个问题?

3 个答案:

答案 0 :(得分:1)

不知道。但是好像gitlab.com删除了我的跑步者令牌。因此,我必须删除跑步者,注册并再次运行。

答案 1 :(得分:1)

我是第一次集成我的跑步者,任何熟悉 gitlab 的人都会知道这永远不会是在公园里散步。我花了很多时间追查这条错误消息,结果发现我完全看错了方向。

ERROR: Checking for jobs... forbidden               runner=s3xBVnW8
ERROR: Checking for jobs... forbidden               runner=s3xBVnW8
ERROR: Checking for jobs... forbidden               runner=s3xBVnW8
ERROR: Runner https://gitlab.com/s3xBVnW8JZPTaocALN3i is not healthy and will be disabled!

我现在相信我的跑步者告诉我 gitlab.com 上的“跑步者”不健康并且已被(我的跑步者)拒绝。当我让它运行并放入管道作业时,它处理得很好,最后没有问题,我花了几个小时寻找任何东西!

答案 2 :(得分:0)

我遇到了同样的问题。按照安装说明中的说明注册您的跑步者。转到 admin/runners 并单击 Show runner installation instructions 按钮。最重要的是 Register runner 会话,您必须在其中运行 register 命令来解决所描述的问题。例如,linux:

sudo gitlab-runner register --url YOUR_GITLAB_SERVER_URL --registration-token TOKEN

# YOUR_GITLAB_SERVER_URL like http://localhost:8100/ or https://mygitlabserver.com/

按照说明操作即可。

一旦您的运行器设置并运行,您就可以向配置文件添加修改,在配置更改后停止并重新启动它。

您可能会发现重复的 [[runners]] 部分,如果您尝试自己配置它然后使用 register 命令会发生这种情况。没关系,只留下最新的。