{{- if .Values.envoy.deploy -}} apiVersion: v1 kind: Service metadata: name: {{ .Values.envoy.name }} namespace: {{ .Values.namespace }} labels: app: {{ .Values.envoy.name }} annotations: # ensures the service is created at the end "helm.sh/hook": post-install "helm.sh/hook-weight": "-5" spec: type: LoadBalancer {{- if .Values.kubevip.deploy }} loadBalancerClass: {{ .Values.kubevip.loadBalancerClass }} {{- end }} externalTrafficPolicy: Local ports: - name: {{ .Values.tinkServer.name }} port: {{ .Values.tinkServer.port.hostPort }} targetPort: {{ .Values.tinkServer.port.hostPort }} protocol: TCP - name: {{ .Values.hegel.name }} port: {{ .Values.hegel.port.hostPort }} targetPort: {{ .Values.hegel.port.hostPort }} protocol: TCP loadBalancerIP: {{ .Values.envoy.externalIp }} selector: app: {{ .Values.envoy.name }} {{- end -}}