Skip to content

Support providing a password specifically for Sentinels

Summary

I have the external redis with sentinel configured. Next I was config gitlab helm chart follow this document

https://docs.gitlab.com/charts/advanced/external-redis/#using-multiple-redis-instances

this is my config

global:
  redis:
    host: redis-master
    port: 6379
    sentinels:
      - host: redis-db.redis-db
        port: 26379
    password:
      enabled: true
      secret: gitlab-redis-db-password
      key: password

Everything OK. BUT, when webservice deployment are deployed. It was error at Init 2/3, and I was investigated that at container init called dependencies show log as below

  • exec /scripts/exec-env /scripts/wait-for-deps Checking: resque.yml, cable.yml
  • FAILED connecting to 'redis://redis-master:6379' from resque.yml, through redis-master ERROR: NOAUTH Authentication required.
  • FAILED connecting to 'redis://redis-master:6379' from cable.yml, through redis-master ERROR: NOAUTH Authentication required.

And my redis server have AUTH setting. I see that at dependencies, it was passed sentinel to get master, and after connect to "global.redis.host", it shows error at above. I think config init container dependencies have issue and maybe password.enable: true not work. Please check and fix it !

https://gitlab.com/gitlab-org/charts/gitlab/-/blob/v5.2.4/charts/gitlab/charts/webservice/templates/deployment.yaml#L133

Steps to reproduce

(Please provide the steps to reproduce the issue)

Configuration used

global:
  redis:
    host: redis-master
    port: 6379
    sentinels:
      - host: redis-db.redis-db
        port: 26379
    password:
      enabled: true
      secret: gitlab-redis-db-password
      key: password

Current behavior

Init 2/3 Fail at webservice deployment

Expected behavior

Passed init and running at webservice deployment

Versions

  • Chart: 5.2.3, 5.2.4
  • Platform:
    • Cloud: EKS | On-prem
    • Self-hosted: VMware
  • Kubernetes: 1.21
    • Client:
    • Server:
  • Helm: 3
    • Client:
    • Server:

Relevant logs