argocd-helm/charts/argo-rollouts/templates/dashboard/service.yaml
Sergey Shaykhullin 1794ba17bf
feat(argo-rollouts): Add rollouts dashboard ingress support (#870)
* Add rollouts dashboard ingress support

Signed-off-by: Sergey Shaykhullin <sergeyshaykhullin@gmail.com>

* Fix eol

Signed-off-by: Sergey Shaykhullin <sergeyshaykhullin@gmail.com>

* Bump version

Signed-off-by: Sergey Shaykhullin <sergeyshaykhullin@gmail.com>

* Update Chart.yaml

Signed-off-by: Sergey Shaykhullin <sergeyshaykhullin@gmail.com>

* Fix service duplication

* Extend warning in terms of exposing the dashboard

Signed-off-by: Marco Kilchhofer <mkilchhofer@users.noreply.github.com>

* Adapt API overrides to other charts (apiVersionOverrides)

Also add missing param 'kubeVersionOverride' to README.

Signed-off-by: Marco Kilchhofer <mkilchhofer@users.noreply.github.com>

* Use consistent code style for empty lists

Signed-off-by: Marco Kilchhofer <mkilchhofer@users.noreply.github.com>

* Fix README `[/]` -> `["/"]`

Signed-off-by: Marco Kilchhofer <mkilchhofer@users.noreply.github.com>

Co-authored-by: Marco Kilchhofer <mkilchhofer@users.noreply.github.com>
2022-01-10 21:44:51 +01:00

40 lines
1.3 KiB
YAML

{{- 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 }}
{{- with .Values.dashboard.service.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
annotations:
{{- with .Values.serviceAnnotations }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.dashboard.service.annotations }}
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
{{- 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 }}
type: {{ .Values.dashboard.service.type }}
ports:
- name: {{ .Values.dashboard.service.portName }}
protocol: TCP
port: {{ .Values.dashboard.service.port }}
targetPort: {{ .Values.dashboard.service.targetPort }}
selector:
app.kubernetes.io/component: {{ .Values.dashboard.component }}
{{- include "argo-rollouts.selectorLabels" . | nindent 4 }}
{{- end }}