Skip to content

Wrong credital key used for redis cache password

when deploying a cloud native hybrid version of gitlab via the GET that uses multiple redis instances (cache and persistent) the wrong config key is used for the the redis cache password. After depoyment, the webservice reports authentication errors for the redis cache instance in its logs.

Checking the helm values shows the following for redis after deployment

 redis:
    auth:
      key: password
      secret: gitlab-redis-persistent-password
    cache:
      auth:
        key: password
        secret: gitlab-redis-cache-password
      host: 10.53.37.71
      port: "6379"
      scheme: redis
    host: 10.55.184.199
    port: "6379"
    scheme: redis

However auth is the wrong key to use. If I update the helm config to use the key password, then gitlab is able to authenticate with the redis cache instance.

 redis:
    auth:
      key: password
      secret: gitlab-redis-persistent-password
    cache:
      password:
        key: password
        secret: gitlab-redis-cache-password
      host: 10.53.37.71
      port: "6379"
      scheme: redis
    host: 10.55.184.199
    port: "6379"
    scheme: redis

According to chart documentation , password does appear to be the right key to use for alternate redis instances instead of auth.

I believe this line in the ansible template is the cause of the bug: https://gitlab.com/gitlab-org/gitlab-environment-toolkit/-/blob/main/ansible/roles/gitlab_charts/templates/gitlab.yml.j2?ref_type=heads#L438

I am using the latest version of the GET which installs the latest version of GitLab. The specific version of GitLab that was installed is v17.6.2-ee.

Edited by Brian Bechtel
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information