chore(helm): disabling redis string if not enabled (#1153)

Signed-off-by: rjshrjndrn <rjshrjndrn@gmail.com>
This commit is contained in:
Rajesh Rajendran 2023-04-12 16:25:45 +02:00 committed by rjshrjndrn
parent 26a142c7ab
commit cce3675e57
2 changed files with 3 additions and 2 deletions

View file

@ -51,8 +51,7 @@ spec:
value: '{{ .Values.global.s3.region }}'
- name: LICENSE_KEY
value: '{{ .Values.global.enterpriseEditionLicense }}'
- name: REDIS_STRING
value: '{{ .Values.global.redis.redisHost }}:{{ .Values.global.redis.redisPort }}'
{{- include "openreplay.env.redis_string" .Values.global.redis | nindent 12 }}
- name: KAFKA_SERVERS
value: '{{ .Values.global.kafka.kafkaHost }}:{{ .Values.global.kafka.kafkaPort }}'
- name: KAFKA_USE_SSL

View file

@ -65,6 +65,7 @@ Create the name of the service account to use
Create the environment configuration for REDIS_STRING
*/}}
{{- define "openreplay.env.redis_string" -}}
{{- if .enabled }}
{{- $scheme := (eq (.tls | default dict).enabled true) | ternary "rediss" "redis" -}}
{{- $auth := "" -}}
{{- if or .existingSecret .redisPassword -}}
@ -83,6 +84,7 @@ Create the environment configuration for REDIS_STRING
- name: REDIS_STRING
value: '{{ $scheme }}://{{ $auth }}{{ .redisHost }}:{{ .redisPort }}'
{{- end }}
{{- end }}
{{/*
Create the volume mount config for redis TLS certificates