oc-k8s/opencloud/templates/oc-shared/ingress.yaml

32 lines
744 B
YAML
Raw Normal View History

2025-01-09 16:24:43 +01:00
{{- if index .Values.ocShared.enabled }}
apiVersion: traefik.io/v1alpha1
kind: IngressRoute
metadata:
name: oc-shared-ingress
spec:
entryPoints:
- web
routes:
- kind: Rule
match: Host(`{{ .Values.host }}`) && PathPrefix(`/shared`)
priority: 10
services:
- kind: Service
name: oc-shared-svc
port: 8080
middlewares:
- name: strip-shared-prefix
{{- if index .Values.ocAuth.enableTraefikProxyIntegration }}
- name: forward-auth
{{- end }}
2025-01-09 16:24:43 +01:00
---
apiVersion: traefik.io/v1alpha1
kind: Middleware
metadata:
name: strip-shared-prefix
spec:
2025-03-27 13:04:29 +01:00
replacePathRegex:
regex: ^/shared(.*)
replacement: /oc$1
2025-01-09 16:24:43 +01:00
{{- end }}