Installation of gitlab-ee on kubernetes fails if we disable minio, due to object store details for external_diff not being available.
Summary
Installation of gitlab-ee:v11.9.0 on kubernetes fails if we disable minio, due to external_diff object store not being available.
Steps to reproduce
- Set global.minio.enabled false
- Provide gcs sceret connection details as prescribed in https://gitlab.com/charts/gitlab/tree/master/doc/advanced/external-object-storage
- Run the helm command.
- Gitlab unicorn, sidekiq, taskrunner all fail on dependencies init as
What is the current bug behavior?
Kubenertes pod init fails as /etc/gitlab/objectstorage/external_diffs is not found and unicorn, sidekiq, taskrunner endup in crashbackloop.
What is the expected correct behavior?
Init should pass and unicorn, sidekiq, taskrunner should get into running state.
Relevant logs and/or screenshots
/usr/lib/ruby/2.5.0/psych.rb:497:in initialize': No such file or directory @ rb_sysopen - /etc/gitlab/objectstorage/external_diffs (Errno::ENOENT) from /usr/lib/ruby/2.5.0/psych.rb:497:in
open'
from /usr/lib/ruby/2.5.0/psych.rb:497:in load_file' from (erb):49:in
'
from /usr/lib/ruby/2.5.0/erb.rb:876:in eval' from /usr/lib/ruby/2.5.0/erb.rb:876:in
result'
from /scripts/set-config:22:in block in <main>' from /scripts/set-config:18:in
each'
from /scripts/set-config:18:in `'
Begin parsing .erb files from /var/opt/gitlab/templates
Writing /srv/gitlab/config/resque.yml
Writing /srv/gitlab/config/gitlab.yml
Results of GitLab environment info
Running on kubernetes GKE cluster
Results of GitLab application Check
Running on kubernetes GKE cluster
Possible fixes
Initialization is reading the /var/opt/gitlab/templates/ folder to pick up templates. gitlab.yml.erb mentions about external_diff and even if enable is set to false, the set-config script in /script trys to check for file /etc/gitlab/objectstorage/external_diffs Even if we provide the connection details in the values.yml while using helm template, we are getting the same error.
I have found that, deployment.yaml in charts_git/gitlab/charts/gitlab/charts/unicorn/templates/ and charts_git/gitlab/charts/gitlab/charts/sidekiq/templates and charts_git/gitlab/charts/gitlab/charts/task-runner/templates does not have the line "{{- include "gitlab.appConfig.objectStorage.mountSecrets" (dict "name" "external_diffs" "config" $.Values.global.appConfig.externalDiffs) | nindent 10 }}"
I have tried including this in the templates the pods come to running state.