gitlab-rails-secret is not created when installing GitLab using Helm Chart
Summary
I tried to install Gitlab using Helm Chart (version 2.1.2
) to my Kubernetes and I got this error:
Warning FailedMount 5s (x9 over 2m13s) kubelet, ip-172-20-38-133.eu-central-1.compute.internal MountVolume.SetUp failed for volume "init-task-runner-secrets" : secret "gitlab-rails-secret" not found
Steps to reproduce
helm install --name gitlab --namespace gitlab-system --wait gitlab/gitlab --version 2.1.2 --set global.hosts.domain=myexample.com --set certmanager.install=false --set global.ingress.configureCertmanager=false
Error: release gitlab failed: timed out waiting for the condition
Some pods hanged in Init state:
$ kubectl get pods -n gitlab-system
NAME READY STATUS RESTARTS AGE
gitlab-gitaly-0 0/1 Running 0 76s
gitlab-gitlab-monitor-7ffd856bfb-c2kww 1/1 Running 0 79s
gitlab-gitlab-runner-5b7869886f-289lm 0/1 Running 0 79s
gitlab-gitlab-shell-5f9b9b76cb-7qz22 1/1 Running 0 79s
gitlab-gitlab-shell-5f9b9b76cb-nswdl 1/1 Running 0 59s
gitlab-migrations.1-x9p6l 0/1 Init:0/2 0 76s
gitlab-minio-5746f7f7c7-dbzsg 1/1 Running 0 78s
gitlab-minio-create-buckets.1-bn75p 0/1 Completed 0 76s
gitlab-nginx-ingress-controller-77cc5c9c9-9w89q 1/1 Running 0 77s
gitlab-nginx-ingress-controller-77cc5c9c9-b6mgg 1/1 Running 0 78s
gitlab-nginx-ingress-controller-77cc5c9c9-lb98r 1/1 Running 0 77s
gitlab-nginx-ingress-default-backend-5c4b7cd5-kxc9x 1/1 Running 0 78s
gitlab-nginx-ingress-default-backend-5c4b7cd5-lnlkp 1/1 Running 0 77s
gitlab-postgresql-554d9fc6d5-7s9m7 2/2 Running 0 77s
gitlab-prometheus-server-5d6bd77b87-lkqlj 2/2 Running 0 76s
gitlab-redis-57c89f6bf5-ml9p9 2/2 Running 0 76s
gitlab-registry-b75b96d88-h9snw 1/1 Running 0 76s
gitlab-registry-b75b96d88-twk8n 1/1 Running 0 75s
gitlab-sidekiq-all-in-1-5744b6747c-tn8gl 0/1 Init:0/3 0 79s
gitlab-task-runner-599fd56d78-8t2lc 0/1 Init:0/2 0 79s
gitlab-unicorn-79cc9d8f7f-qp9nq 0/2 Init:0/3 0 78s
gitlab-unicorn-79cc9d8f7f-sjfr5 0/2 Init:0/3 0 59s
If I check the details from one of the hanged pod I can see:
$ kubectl describe pods -n gitlab-system gitlab-task-runner-599fd56d78-8t2lc
Events:
Type Reason Age From Message
---- ------ ---- ---- -------
Normal Scheduled 2m13s default-scheduler Successfully assigned gitlab-system/gitlab-task-runner-599fd56d78-8t2lc to ip-172-20-38-133.eu-central-1.compute.internal
Warning FailedMount 10s kubelet, ip-172-20-38-133.eu-central-1.compute.internal Unable to mount volumes for pod "gitlab-task-runner-599fd56d78-8t2lc_gitlab-system(4f04d931-b2c8-11e9-964c-02bcb87342ac)": timeout expired waiting for volumes to attach or mount for pod "gitlab-system"/"gitlab-task-runner-599fd56d78-8t2lc". list of unmounted volumes=[init-task-runner-secrets]. list of unattached volumes=[task-runner-config task-runner-tmp init-task-runner-secrets task-runner-secrets etc-ssl-certs custom-ca-certificates default-token-5d4tx]
Warning FailedMount 5s (x9 over 2m13s) kubelet, ip-172-20-38-133.eu-central-1.compute.internal MountVolume.SetUp failed for volume "init-task-runner-secrets" : secret "gitlab-rails-secret" not found
Secret gitlab-rails-secret
is really not created:
$ kubectl get secrets -n gitlab-system gitlab-rails-secret
Error from server (NotFound): secrets "gitlab-rails-secret" not found
Note - when I used older helm chart version 1.9.7
everything works fine - for example:
helm install --name gitlab --namespace gitlab-system --wait gitlab/gitlab --version 1.9.7 --set global.hosts.domain=myexample.com --set certmanager.install=false --set global.ingress.configureCertmanager=false
Configuration used
Kubernetes in AWS created by kops.
Versions
- Chart: 2.1.2
- Platform:
- Cloud: AWS / kops
- Kubernetes: (
kubectl version
)- Client: v1.14.2
- Server: v1.14.1
- Helm: (
helm version
)- Client: v2.14.1
- Server: v2.14.1