blob: 1aded3c09cf9d64e5885a1d790c5c4b6496ee616 [file] [log] [blame]
vagrant1a3a3552018-03-10 23:56:32 +00001apiVersion: v1
2kind: Service
3metadata:
BorislavG26b650f2018-05-13 17:11:01 +00004 name: {{ include "common.servicename" . }}
vagrant1a3a3552018-03-10 23:56:32 +00005 namespace: {{ include "common.namespace" . }}
6 labels:
BorislavG26b650f2018-05-13 17:11:01 +00007 app: {{ include "common.name" . }}
8 chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
9 release: {{ .Release.Name }}
10 heritage: {{ .Release.Service }}
11 annotations:
12 service.alpha.kubernetes.io/tolerate-unready-endpoints: "true"
vagrant1a3a3552018-03-10 23:56:32 +000013spec:
vagrant1a3a3552018-03-10 23:56:32 +000014 type: {{ .Values.service.type }}
BorislavG26b650f2018-05-13 17:11:01 +000015# Not working, open k8s bug: https://github.com/kubernetes/kubernetes/issues/58662
16 publishNotReadyAddresses: true
vagrant1a3a3552018-03-10 23:56:32 +000017 ports:
BorislavG26b650f2018-05-13 17:11:01 +000018 {{if eq .Values.service.type "NodePort" -}}
19 - port: {{ .Values.service.internalPort }}
20 nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort }}
21 name: {{ .Values.service.portName }}
22 - port: {{ .Values.service.internalPort2 }}
23 nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort2 }}
24 name: {{ .Values.service.portName3 }}
25 - port: {{ .Values.service.internalPort3 }}
26 nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort3 }}
27 name: {{ .Values.service.portName3 }}
28 {{- else -}}
29 - port: {{ .Values.service.internalPort }}
30 name: {{ .Values.service.portName }}
31 - port: {{ .Values.service.internalPort2 }}
32 name: {{ .Values.service.portName2 }}
33 - port: {{ .Values.service.internalPort3 }}
34 name: {{ .Values.service.portName3 }}
35 {{- end}}
vagrant1a3a3552018-03-10 23:56:32 +000036 selector:
BorislavG26b650f2018-05-13 17:11:01 +000037 app: {{ include "common.name" . }}
38 release: {{ .Release.Name }}
39 clusterIP: None