commerce.cruzcloud.net (medusa-svc) has no route at "/" — Medusa only serves /health, /app (admin), /store, etc. lab-agent's generic public domain check flagged the resulting 404 as an anomaly every cycle even though the service is healthy. Adds a Traefik Middleware (redirectRegex) scoped to the commerce host that 301s "/" to "/app", so the DNS/routing layer owns the entry point instead of every client (including monitoring) having to know to append /app manually. Regex includes the host explicitly because the same Ingress also routes media.cruzcloud.net and shares router.middlewares at the Ingress-annotation level.
32 lines
777 B
YAML
32 lines
777 B
YAML
apiVersion: networking.k8s.io/v1
|
|
kind: Ingress
|
|
metadata:
|
|
name: commerce-ingress
|
|
annotations:
|
|
traefik.ingress.kubernetes.io/router.entrypoints: web
|
|
traefik.ingress.kubernetes.io/router.middlewares: ecommerce-commerce-redirect-app@kubernetescrd
|
|
spec:
|
|
ingressClassName: traefik
|
|
rules:
|
|
- host: commerce.cruzcloud.net
|
|
http:
|
|
paths:
|
|
- path: /
|
|
pathType: Prefix
|
|
backend:
|
|
service:
|
|
name: medusa-svc
|
|
port:
|
|
number: 9000
|
|
|
|
- host: media.cruzcloud.net
|
|
http:
|
|
paths:
|
|
- path: /
|
|
pathType: Prefix
|
|
backend:
|
|
service:
|
|
name: minio-svc
|
|
port:
|
|
number: 9000
|