strip /ip prefix for ip listner middleware test

This commit is contained in:
Mans Ziesel 2024-09-22 14:21:05 +02:00
parent df2aae5134
commit 9a55885a1d

View File

@ -3,15 +3,25 @@ kind: Ingress
metadata: metadata:
name: ip-mzisel-nl-ingress name: ip-mzisel-nl-ingress
annotations: annotations:
nginx.ingress.kubernetes.io/rewrite-target: /$2 traefik.ingress.kubernetes.io/middlewares: default-strip-ip-prefix@kubernetescrd
spec: spec:
rules: rules:
- http: - http:
paths: paths:
- path: /ip(/|$)(.*) - path: /ip
pathType: Prefix pathType: Prefix
backend: backend:
service: service:
name: ip-mziesel-nl name: ip-mziesel-nl
port: port:
name: web name: web
---
apiVersion: traefik.io/v1alpha1
kind: Middleware
metadata:
name: strip-ip-prefix
spec:
stripPrefix:
prefixes:
- "/ip"
forceSlash: false