1

I have a self-hosted instance of gitlab and a server with a couple of gitlab runners using docker as executors.

When a new CI-job is started, it always takes at least 2minutes before I see the result, but when I check the docker logs of the created container, It is finished with the build after 20s. Where could the problem be?

My config.toml:

concurrent = 10
check_interval = 0

[session_server]
  session_timeout = 1800

[[runners]]
  name = "Runner 02"
  url = "https://gitlab.<myUrl>.ch/"
  token = "myToken"
  executor = "docker"
  environment = ["DOCKER_DRIVER=overlay2"]
  [runners.docker]
    tls_verify = false
    image = "docker"
    privileged = false
    disable_cache = false
    volumes = ["/var/run/docker.sock:/var/run/docker.sock", "/root/.ssh:/root/.ssh", "/cache", "/root/.m2:/root/.m2"]
    shm_size = 0

The runner is registered as group runner.

CyrillC
  • 557
  • 1
  • 3
  • 15

1 Answers1

0

The problem lies in the access from the Gitlab runner to the Gitlab server.

When the Runner can't send updates to the server, the server pulls updates after ~2min. In my case, the firewall blocked the call from the runner to the server. Switching to an internal name server omitting the firewall fixed the issue.

CyrillC
  • 557
  • 1
  • 3
  • 15