diff --git a/operator/redisfailover/service/generator.go b/operator/redisfailover/service/generator.go index f53fbca94..83d3521e9 100644 --- a/operator/redisfailover/service/generator.go +++ b/operator/redisfailover/service/generator.go @@ -970,7 +970,7 @@ func getRedisEnv(rf *redisfailoverv1.RedisFailover) []corev1.EnvVar { }) env = append(env, corev1.EnvVar{ - Name: "REDIS_USERNAME", + Name: "REDIS_USER", Value: "default", }) diff --git a/test/integration/redisfailover/creation_test.go b/test/integration/redisfailover/creation_test.go index e19900dfa..00eb5c656 100644 --- a/test/integration/redisfailover/creation_test.go +++ b/test/integration/redisfailover/creation_test.go @@ -268,7 +268,7 @@ func (c *clients) testAuth(t *testing.T) { assert.Equal(redisSS.Spec.Template.Spec.Containers[1].Env[1].Value, redisAddr) assert.Equal(redisSS.Spec.Template.Spec.Containers[1].Env[2].Name, "REDIS_PORT") assert.Equal(redisSS.Spec.Template.Spec.Containers[1].Env[2].Value, "6379") - assert.Equal(redisSS.Spec.Template.Spec.Containers[1].Env[3].Name, "REDIS_USERNAME") + assert.Equal(redisSS.Spec.Template.Spec.Containers[1].Env[3].Name, "REDIS_USER") assert.Equal(redisSS.Spec.Template.Spec.Containers[1].Env[3].Value, "default") assert.Equal(redisSS.Spec.Template.Spec.Containers[1].Env[4].Name, "REDIS_PASSWORD") assert.Equal(redisSS.Spec.Template.Spec.Containers[1].Env[4].ValueFrom.SecretKeyRef.Key, "password")