Files
chart/library/ix-dev/community/redis/templates/_validation.tpl
Stavros Kois 60dcd5adbf NAS-122432 / 23.10 / add redis to community train (#1261)
* add `redis` to `community` train

* add extra validation

* add error message

* enclose pattern in squotes

* bump common
2023-07-03 14:51:09 +03:00

12 lines
414 B
Smarty

{{- define "redis.validation" -}}
{{- if not .Values.redisConfig.allowEmptyPassword -}}
{{- if not .Values.redisConfig.password -}}
{{- fail "Redis - Field [Password] is required when [Allow Empty Password] is false" -}}
{{- end -}}
{{- if contains "@" .Values.redisConfig.password -}}
{{- fail "Redis - Field [Password] cannot contain '@'" -}}
{{- end -}}
{{- end -}}
{{- end -}}