blob: 94ec4694a379f06b7b14216b58a36d8613e48214 [file] [log] [blame]
vaibhav_16decf67e4182018-03-19 05:45:47 +00001apiVersion: v1
2kind: Service
3metadata:
4 name: {{ include "common.fullname" . }}
5 namespace: {{ include "common.namespace" . }}
6 labels:
7 app: {{ include "common.name" . }}
8 chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
9 release: {{ .Release.Name }}
10 heritage: {{ .Release.Service }}
11spec:
12 type: {{ .Values.service.type }}
13 ports:
14 {{if eq .Values.service.type "NodePort" -}}
15 - port: {{ .Values.service.internalPort }}
16 nodePort: {{ .Values.global.nodePortPrefix | default "302" }}{{ .Values.service.nodePort }}
17 {{- else -}}
18 - port: {{ .Values.service.externalPort }}
19 targetPort: {{ .Values.service.internalPort }}
20 {{- end}}
21 name: {{ .Values.service.name }}
22 selector:
23 app: {{ include "common.name" . }}
24 release: {{ .Release.Name }}