root@debian:~/authelia# cat cc.yaml
apiVersion: traefik.io/v1alpha1
kind: IngressRoute
metadata:
name: tool-service
namespace: hdh5
spec:
entryPoints:
- websecure
routes:
- kind: Rule
match: Host(`link.h.example.com.cn`)
priority: 10
services:
- name: tool-service
port: 80
tls:
secretName: link-tls
When I use only the resources in the OP I can access https://link.h.example.com.cn properly
But when I use the resource below, it returns 404,I think the problem is in the middleware configuration
root@debian:~/authelia# cat link.yaml
apiVersion: traefik.io/v1alpha1
kind: IngressRoute
metadata:
name: tool-service
namespace: hdh5
spec:
entryPoints:
- websecure
routes:
- kind: Rule
match: Host(`link.h.example.com.cn`)
middlewares:
- name: authelia-auth
namespace: authelia
priority: 10
services:
- name: tool-service
port: 80
tls:
secretName: link-tls
---
apiVersion: traefik.io/v1alpha1
kind: Middleware
metadata:
name: authelia-auth
namespace: authelia
spec:
forwardAuth:
address: http://authelia.authelia.svc.cluster.local:9091/api/authz/forward-auth?rd=https://op.h.example.com.cn/
trustForwardHeader: true
authResponseHeaders:
- Remote-User
- Remote-Groups
- Remote-Name
- Remote-Email