Nav apraksta

frontend-svc.yaml 1.2KB

12345678910111213141516171819202122232425262728
  1. apiVersion: v1
  2. kind: Service
  3. metadata:
  4. name: {{ template "shuffle.frontend.name" . }}
  5. namespace: {{ include "common.names.namespace" . | quote }}
  6. {{- $serviceLabels := include "common.tplvalues.merge" (dict "values" (list .Values.frontend.service.labels .Values.commonLabels) "context" .) }}
  7. labels: {{- include "shuffle.frontend.labels" (dict "customLabels" $serviceLabels "context" $) | nindent 4 }}
  8. {{- if .Values.commonAnnotations }}
  9. annotations: {{- include "common.tplvalues.render" (dict "value" .Values.commonAnnotations "context" $) | nindent 4 }}
  10. {{- end }}
  11. spec:
  12. type: ClusterIP
  13. ports:
  14. - name: http
  15. port: {{ .Values.frontend.containerPorts.http }}
  16. targetPort: http
  17. protocol: TCP
  18. appProtocol: http
  19. {{- if .Values.frontend.containerPorts.https }}
  20. - name: https
  21. port: {{ .Values.frontend.containerPorts.https }}
  22. targetPort: https
  23. protocol: TCP
  24. appProtocol: https
  25. {{- end }}
  26. {{- $podLabels := include "common.tplvalues.merge" (dict "values" (list .Values.frontend.podLabels .Values.commonLabels) "context" .) }}
  27. selector: {{- include "shuffle.frontend.matchLabels" (dict "customLabels" $podLabels "context" $) | nindent 4 }}