Runner configmap is not created and pod does not start
I've installed the operator version 1.10.0 via OperatorHub on an OpenShift 4.9 cluster in the namespace gitlab-runner
.
When I try to create a simple runner:
apiVersion: apps.gitlab.com/v1beta2
kind: Runner
metadata:
name: dev
spec:
buildImage: alpine
gitlabUrl: https://gitlab.intern
tags: dev, test
token: gitlab-runner-secret
The created pod cannot start with the following event:
MountVolume.SetUp failed for volume "scripts" : configmap "dev-runner-config" not found
Indeed the configmap is not created. Looking at the operator log the following message can be found:
2022-12-15T13:37:14.321Z INFO controllers.Runner Reconciling Runner {"runner": "gitlab-runner/dev", "name": "dev", "namespace": "gitlab-runner"}
2022-12-15T13:37:14.333Z ERROR controllers.Runner Error appending configmap checksums {"runner": "gitlab-runner/dev", "error": "ConfigMap \"dev-runner-config\" not found"}
github.com/go-logr/zapr.(*zapLogger).Error
/go/pkg/mod/github.com/go-logr/zapr@v0.2.0/zapr.go:132
gitlab.com/gitlab-org/gl-openshift/gitlab-runner-operator/controllers.(*RunnerReconciler).reconcileDeployments
/workspace/controllers/runner_controller.go:243
gitlab.com/gitlab-org/gl-openshift/gitlab-runner-operator/controllers.(*RunnerReconciler).Reconcile
/workspace/controllers/runner_controller.go:119
sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).reconcileHandler
/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/internal/controller/controller.go:263
sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).processNextWorkItem
/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/internal/controller/controller.go:235
sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Start.func1.1
/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/internal/controller/controller.go:198
k8s.io/apimachinery/pkg/util/wait.JitterUntilWithContext.func1
/go/pkg/mod/k8s.io/apimachinery@v0.19.2/pkg/util/wait/wait.go:185
k8s.io/apimachinery/pkg/util/wait.BackoffUntil.func1
/go/pkg/mod/k8s.io/apimachinery@v0.19.2/pkg/util/wait/wait.go:155
k8s.io/apimachinery/pkg/util/wait.BackoffUntil
/go/pkg/mod/k8s.io/apimachinery@v0.19.2/pkg/util/wait/wait.go:156
k8s.io/apimachinery/pkg/util/wait.JitterUntil
/go/pkg/mod/k8s.io/apimachinery@v0.19.2/pkg/util/wait/wait.go:133
k8s.io/apimachinery/pkg/util/wait.JitterUntilWithContext
/go/pkg/mod/k8s.io/apimachinery@v0.19.2/pkg/util/wait/wait.go:185
k8s.io/apimachinery/pkg/util/wait.UntilWithContext
/go/pkg/mod/k8s.io/apimachinery@v0.19.2/pkg/util/wait/wait.go:99
The namespace has only these configmaps:
oc get cm
NAME DATA AGE
b43e192d.gitlab.com 0 27h
gitlab-runner-config 6 6m29s
kube-root-ca.crt 1 27h
openshift-service-ca.crt 1 27h