TrueChartsClone/charts/core/traefik/templates/_ingressroute.tpl

26 lines
629 B
Smarty
Raw Normal View History

{{/* Define the ingressRoute */}}
{{- define "traefik.ingressRoute" -}}
{{ if .Values.ingressRoute.dashboard.enabled }}
---
apiVersion: traefik.containo.us/v1alpha1
kind: IngressRoute
metadata:
name: {{ include "common.names.fullname" . }}-dashboard
annotations:
2021-09-07 07:43:55 +00:00
{{- with .Values.ingressRoute.dashboard.annotations }}
{{- toYaml . | nindent 4 }}
{{- end }}
labels:
{{- include "common.labels" . | nindent 4 }}
spec:
entryPoints:
2021-09-03 16:59:18 +00:00
- main
routes:
- match: PathPrefix(`/dashboard`) || PathPrefix(`/api`)
kind: Rule
services:
- name: api@internal
kind: TraefikService
{{ end }}
{{- end -}}