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