Skip to content

Commit

Permalink
feat: provide redis.clusterEndpoints option
Browse files Browse the repository at this point in the history
  • Loading branch information
omidasadpour authored and endersonmaia committed Aug 24, 2023
1 parent ac2d88e commit 8bb8cee
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 2 deletions.
12 changes: 12 additions & 0 deletions charts/rollups-validator-node/templates/dispatcher-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,15 @@ spec:
- {{ print "--tx-chain-id=" (include "dapp.chainID" .) | quote }}
{{- end }}
{{- if .Values.redis.enabled }}
{{- if eq .Values.redis.architecture "replication" }}
- {{ print "--redis-cluster-endpoints=redis://" .Release.Name "-redis-master" | quote }}
{{- else if eq .Values.redis.architecture "standalone" }}
- {{ print "--redis-endpoint=redis://" .Release.Name "-redis-master" | quote }}
{{- end }}
{{- else if .Values.redis.endpoint }}
- {{ print "--redis-endpoint=" .Values.redis.endpoint | quote }}
{{- else if .Values.redis.clusterEndpoints }}
- {{ print "--redis-cluster-endpoints=" (join "," .Values.redis.clusterEndpoints) | quote }}
{{- end }}
{{- range .Values.validator.dispatcher.args }}
- {{ . | quote}}
Expand Down Expand Up @@ -198,9 +204,15 @@ spec:
- {{ print "--chain-id=" (include "dapp.chainID" .) | quote }}
{{- end }}
{{- if .Values.redis.enabled }}
{{- if eq .Values.redis.architecture "replication" }}
- {{ print "--redis-cluster-endpoints=redis://" .Release.Name "-redis-master" | quote }}
{{- else if eq .Values.redis.architecture "standalone" }}
- {{ print "--redis-endpoint=redis://" .Release.Name "-redis-master" | quote }}
{{- end }}
{{- else if .Values.redis.endpoint }}
- {{ print "--redis-endpoint=" .Values.redis.endpoint | quote }}
{{- else if .Values.redis.clusterEndpoints }}
- {{ print "--redis-cluster-endpoints=" (join "," .Values.redis.clusterEndpoints) | quote }}
{{- end }}
{{- range .Values.validator.indexer.args }}
- {{ . | quote}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,15 @@ spec:
- {{ print "--dapp-contract-address=" .Values.dapp.contractAddress | quote }}
{{- end }}
{{- if .Values.redis.enabled }}
{{- if eq .Values.redis.architecture "replication" }}
- {{ print "--redis-cluster-endpoints=redis://" .Release.Name "-redis-master" | quote }}
{{- else if eq .Values.redis.architecture "standalone" }}
- {{ print "--redis-endpoint=redis://" .Release.Name "-redis-master" | quote }}
{{- end }}
{{- else if .Values.redis.endpoint }}
- {{ print "--redis-endpoint=" .Values.redis.endpoint | quote }}
{{- else if .Values.redis.clusterEndpoints }}
- {{ print "--redis-cluster-endpoints=" (join "," .Values.redis.clusterEndpoints) | quote }}
{{- end }}
{{- range .Values.serverManager.advanceRunner.args }}
- {{ . | quote}}
Expand Down
7 changes: 5 additions & 2 deletions charts/rollups-validator-node/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -827,13 +827,16 @@ redis:
# -- Use bitnami Redis® pod.
enabled: true
# -- redis.endpoint: e.g.: redis://localhost:6379
# REQUIRED if you disabled redis
# REQUIRED if you disabled redis and your redis is standalone
endpoint:
# -- redis.clusterEndpoints: e.g.: [ "redis://localhost:6379" ]
# REQUIRED if you disabled redis and your redis is cluster
clusterEndpoints: []
image:
# -- Redis® docker image tag.
tag: 6.2-debian-11
# -- Redis® architecture. Allowed values: `standalone` or `replication`
architecture: standalone
architecture: replication
auth:
# -- Redis® Enable password authentication
enabled: false
Expand Down

0 comments on commit 8bb8cee

Please sign in to comment.