Skip to content

Commit

Permalink
AP-4505: Match redis chart hostname logic
Browse files Browse the repository at this point in the history
Use a different redis host name depending on whether the
release name contains the name of the chart, "redis".

TODO: look into using `.Values.nameOverride` and or
a helm template or helper as an alternative to hardcoding
the chart name.
  • Loading branch information
jsugarman committed Oct 17, 2023
1 parent 52ad06f commit bff55fa
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions helm_deploy/apply-for-legal-aid/templates/_envs.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,11 @@ env:
- name: REDIS_PROTOCOL
value: "redis"
- name: REDIS_HOST
{{ if contains "redis" .Release.Name }}
value: {{ printf "%s-%s.%s.%s" .Release.Name "master" .Release.Namespace "svc.cluster.local" }}
{{ else }}
value: {{ printf "%s-%s.%s.%s" .Release.Name "redis-master" .Release.Namespace "svc.cluster.local" }}
{{ end }}
- name: REDIS_PASSWORD
valueFrom:
secretKeyRef:
Expand Down

0 comments on commit bff55fa

Please sign in to comment.