You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{- fail "built-in Redis does not support component-specific passwords; use metadata.redis.enablePassword/password for shared built-in Redis auth or disable built-in Redis for external Redis passwords." -}}
172
170
{{- end -}}
171
+
173
172
{{- end -}}
174
173
175
174
{{/*
176
175
Return whether the shared Redis password config is enabled.
177
176
*/}}
178
177
{{- define"aibrix.redis.sharedHasPassword" -}}
179
-
{{- $metadata:= get .Values"metadata"| default dict -}}
180
-
{{- $redis:= get $metadata"redis"| default dict -}}
- it: should set external redis passwd when builtIn is disabled
33
+
set:
34
+
metadata.redis.enabled: false
35
+
gatewayPlugin.dependencies.redis.password: "abcd"
36
+
metadata.service.redis.password: "abdc"
37
+
gpuOptimizer.dependencies.redis.password: "acbd"
38
+
asserts:
39
+
- notExists:
40
+
path: data.redis-password
41
+
- equal:
42
+
path: data.gateway-plugin-redis-password
43
+
value: "YWJjZA=="
44
+
- equal:
45
+
path: data.gpu-optimizer-redis-password
46
+
value: "YWNiZA=="
47
+
- equal:
48
+
path: data.metadata-service-redis-password
49
+
value: "YWJkYw=="
50
+
---
51
+
suite: Test Redis Shared Passwd Conflict
52
+
templates:
53
+
tests:
54
+
- it: should conflict
55
+
set:
56
+
metadata.redis.enabled: true
57
+
gatewayPlugin.dependencies.redis.password: "abcd"
58
+
metadata.service.redis.password: "abdc"
59
+
gpuOptimizer.dependencies.redis.password: "acbd"
60
+
asserts:
61
+
- failedTemplate:
62
+
errorMessage: "built-in Redis does not support component-specific passwords; use metadata.redis.enablePassword/password for shared built-in Redis auth or disable built-in Redis for external Redis passwords."
0 commit comments