Skip to content

Gitlab Runner 11.11.0 breaks volumes for docker executor

Summary

We are using the gitlab-runner's config.toml (see below) to mount various config files into the build process (docker executor), e.g., the Maven settings.xml. This used to work until gitlab-runner 11.10, but apparently broke with the 11.11 update that just happened: The volumes declared in config.toml are no longer mounted and builds are failing since they are missing their config.

Steps to reproduce

Declare volumes in config.toml. Observe the build against gitlab-runner 11.11 and 11.10.

Actual behavior

The volumes are not mounted.

Expected behavior

The volumes should be mounted.

Relevant logs and/or screenshots

./.

Environment description

These are private shared runners attached to a GitLab CE instance. Docker version: 18.09.6

config.toml contents
[[runners]]
  name = "gitlab-runner-<redacted>"
  url = "https://gitlab.<redacted>/ci"
  token = "<redacted>"
  executor = "docker"
  environment = ["DOCKER_HOST=tcp://tgbyte__docker:2375"]
  [runners.docker]
    tls_verify = true
    image = "tgbyte/builder:latest"
    privileged = true
    disable_cache = false
    services = ["tgbyte/docker:dind"]
    volumes = ["/cache", "/srv/gitlab/runner/gcloud/service_accont_key_file.json:/root/.config/gcloud/service_accont_key_file.json:ro", "/srv/gitlab/runner/config/config.json:/root/.docker/config.json:ro", "/srv/gitlab/runner/ssh:/root/.ssh:ro", "/srv/gitlab/runner/mvn/settings.xml:/root/.m2/settings.xml:ro", "/etc/docker/daemon.json:/etc/docker/daemon.json:ro"]
  [runners.cache]
    Insecure = false

Used GitLab Runner version

Running with gitlab-runner 11.11.0 (6c154264)

gitlab/gitlab-runner:ubuntu

Edited by Thilo-Alexander Ginkel