16 lines
428 B
YAML
16 lines
428 B
YAML
|
---
|
||
|
apiVersion: v1
|
||
|
kind: Service
|
||
|
metadata:
|
||
|
name: {{ .Values.name }}
|
||
|
spec:
|
||
|
selector:
|
||
|
app: {{ .Values.name }}
|
||
|
ports:
|
||
|
{{- range .Values.ports}}
|
||
|
- protocol: {{ .protocol | default "TCP" }}
|
||
|
port: {{ .containerPort }}
|
||
|
targetPort: {{ .targetPort | default .containerPort }}
|
||
|
name: {{ .containerPort }}-{{ .protocol | default "TCP" | lower }}-{{ .targetPort | default .containerPort }}
|
||
|
{{- end }}
|