Skip to content

Cannot run jobs after v15.0.0 update

Summary

After updating Gitlab helm release from 14.10 -> 15.0, no jobs can be created.

Steps to reproduce

  1. Update from 14.10 to 15.0
  2. Re-run a green job or run a new job.

Actual behavior

Jobs fail immediately with the following logs:

Running with gitlab-runner 15.0.0 (febb2a09)
  on gitlab-gitlab-runner-7b7ff546cc-4n2s4 QdUFvam1
Preparing the "kubernetes" executor 00:00
Using Kubernetes namespace: gitlab
Using Kubernetes executor with image registry.gitlab.com/gitlab-org/terraform-images/stable:latest ...
Using attach strategy to execute scripts...
Preparing environment 00:05
ERROR: Job failed (system failure): prepare environment: setting up build pod: Timed out while waiting for ServiceAccount/gitlab-runner to be present in the cluster. Check https://docs.gitlab.com/runner/shells/index.html#shell-profile-loading for more information

I have checked, and the gitlab-runner service account still exists in the gitlab namespace. I didn't change any of the values for the helm deployment - just the version of the chart.

Expected behavior

Jobs should still run.

Environment description

Kubernetes executor, Gitlab cloud native helm chart.

config.toml contents
gitlab-runner:
  install: true
  rbac:
    create: false
    serviceAccountName: ${RUNNER_SA}
  runners:
    image: ubuntu:18.04
    serviceAccountName: ${RUNNER_SA}
    locked: false
    config: |
      [[runners]]
        [runners.kubernetes]
          pull_policy = "if-not-present"
          ephemeral_storage_limit = "4Gi"
    cache:
      cacheType: gcs
      gcsBucketName: ${PROJECT_ID}-runner-cache
      secretName: google-application-credentials
      cacheShared: true

Used GitLab Runner version

Running with gitlab-runner 15.0.0 (febb2a09)
  on gitlab-gitlab-runner-7b7ff546cc-4n2s4 QdUFvam1
Using Kubernetes executor with image registry.gitlab.com/gitlab-org/terraform-images/stable:latest ...

Possible fixes

I imagine I need to tweak the values or toml configuration to specify the namespace or the service account for the new version.

Edited by Joel Verezhak