2021-08-16 11:27:24 -04:00
|
|
|
{{- if .Values.dashboard.enabled -}}
|
|
|
|
|
apiVersion: v1
|
|
|
|
|
kind: Service
|
|
|
|
|
metadata:
|
|
|
|
|
name: {{ include "argo-rollouts.fullname" . }}-dashboard
|
|
|
|
|
labels:
|
|
|
|
|
app.kubernetes.io/component: {{ .Values.dashboard.component }}
|
|
|
|
|
{{- include "argo-rollouts.labels" . | nindent 4 }}
|
2022-01-10 23:44:51 +03:00
|
|
|
{{- with .Values.dashboard.service.labels }}
|
|
|
|
|
{{- toYaml . | nindent 4 }}
|
|
|
|
|
{{- end }}
|
2021-08-16 11:27:24 -04:00
|
|
|
annotations:
|
2022-01-10 23:44:51 +03:00
|
|
|
{{- with .Values.serviceAnnotations }}
|
|
|
|
|
{{- toYaml . | nindent 4 }}
|
|
|
|
|
{{- end }}
|
|
|
|
|
{{- with .Values.dashboard.service.annotations }}
|
2021-08-16 11:27:24 -04:00
|
|
|
{{- toYaml . | nindent 4 }}
|
|
|
|
|
{{- end }}
|
|
|
|
|
spec:
|
2022-01-05 13:31:55 +01:00
|
|
|
{{- with .Values.dashboard.service.externalIPs }}
|
|
|
|
|
externalIPs: {{- toYaml . | nindent 4 }}
|
|
|
|
|
{{- end }}
|
|
|
|
|
{{- if eq .Values.dashboard.service.type "LoadBalancer" }}
|
|
|
|
|
{{- with .Values.dashboard.service.loadBalancerIP }}
|
|
|
|
|
loadBalancerIP: {{ . | quote }}
|
|
|
|
|
{{- end }}
|
|
|
|
|
{{- with .Values.dashboard.service.loadBalancerSourceRanges }}
|
|
|
|
|
loadBalancerSourceRanges: {{- toYaml . | nindent 4 }}
|
|
|
|
|
{{- end }}
|
|
|
|
|
{{- end }}
|
2021-12-09 10:12:58 -05:00
|
|
|
type: {{ .Values.dashboard.service.type }}
|
2021-08-16 11:27:24 -04:00
|
|
|
ports:
|
2022-01-10 23:44:51 +03:00
|
|
|
- name: {{ .Values.dashboard.service.portName }}
|
2021-08-16 11:27:24 -04:00
|
|
|
protocol: TCP
|
2022-01-10 23:44:51 +03:00
|
|
|
port: {{ .Values.dashboard.service.port }}
|
|
|
|
|
targetPort: {{ .Values.dashboard.service.targetPort }}
|
2022-02-21 00:01:39 +01:00
|
|
|
{{- if and (eq .Values.dashboard.service.type "NodePort") .Values.dashboard.service.nodePort }}
|
|
|
|
|
nodePort: {{ .Values.dashboard.service.nodePort }}
|
|
|
|
|
{{- end }}
|
2021-08-16 11:27:24 -04:00
|
|
|
selector:
|
|
|
|
|
app.kubernetes.io/component: {{ .Values.dashboard.component }}
|
|
|
|
|
{{- include "argo-rollouts.selectorLabels" . | nindent 4 }}
|
|
|
|
|
{{- end }}
|