forked from zitadel/zitadel-charts
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathservice.yaml
27 lines (27 loc) · 853 Bytes
/
service.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
apiVersion: v1
kind: Service
metadata:
name: {{ include "zitadel.fullname" . }}
{{- if .Values.service }}
{{- with .Values.service.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- end }}
labels:
{{- include "zitadel.labels" . | nindent 4 }}
spec:
type: {{ .Values.service.type }}
{{- if and .Values.service.clusterIP (eq .Values.service.type "ClusterIP") }}
clusterIP: {{ .Values.service.clusterIP }}
{{- end }}
ports:
- port: {{ .Values.service.port }}
targetPort: 8080
protocol: TCP
name: {{ regexReplaceAll "\\W+" .Values.service.protocol "-" }}-server
{{- if semverCompare ">=1.19-0" $.Capabilities.KubeVersion.GitVersion }}
appProtocol: {{ .Values.service.appProtocol }}
{{- end }}
selector:
{{- include "zitadel.selectorLabels" . | nindent 4 }}