暫無描述

shuffle-worker-svc.yaml 1.0KB

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