argocd-helm/charts/argo-cd/templates/redis/service.yaml
Mathieu Parent 1ceb47ff76
feat(argo-cd): Use Istio port name naming convention (#956)
See https://istio.io/latest/docs/ops/configuration/traffic-management/protocol-selection/#explicit-protocol-selection

Signed-off-by: Mathieu Parent <math.parent@gmail.com>

Co-authored-by: Marco Kilchhofer <mkilchhofer@users.noreply.github.com>
2021-10-07 00:12:44 +02:00

23 lines
779 B
YAML

{{- $redisHa := (index .Values "redis-ha") -}}
{{- if and .Values.redis.enabled (not $redisHa.enabled) -}}
apiVersion: v1
kind: Service
metadata:
name: {{ template "argo-cd.redis.fullname" . }}
labels:
{{- include "argo-cd.labels" (dict "context" . "component" .Values.redis.name "name" .Values.redis.name) | nindent 4 }}
{{- with .Values.redis.service.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.redis.service.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
ports:
- name: redis
port: {{ .Values.redis.servicePort }}
targetPort: {{ .Values.redis.containerPort }}
selector:
{{- include "argo-cd.selectorLabels" (dict "context" . "name" .Values.redis.name) | nindent 4 }}
{{- end }}