Traefik Middlewares are used to customize the API Gateway behavior. Middlewares are referenced from IngressRoute. This validator detects a condition when the Middleware referenced in the IngressRoute is not found.
Affected Resources: IngressRoute
apiVersion: traefik.containo.us/v1alpha1
kind: IngressRoute
metadata:
name: whoami
spec:
entryPoints:
- web
routes:
- kind: Rule
match: Host(`demo.kubevious.io`)
middlewares:
- name: samples-security@kubernetescrd # Middleware not found in the namespace "samples"
namespace: samples
- name: redirect # Middleware not found in same namespace
services:
- kind: Service
name: whoami-svc
port: 80
apiVersion: traefik.containo.us/v1alpha1
kind: Middleware
metadata:
name: redirect
spec:
redirectScheme:
permanent: true
scheme: https
Please let us know if there are other built-in validation rules you would like to see in Kubevious to detect misconfigurations and violations to best practices. Optionally, you can provide your details so we can reach out to you with follow-up questions.