Communication Between Traefik and Pods

Hey ,

In the documentation, it says "Traefik automatically requests endpoint information based on the service provided in the ingress spec. Although Traefik will connect directly to the endpoints (pods), it still checks the service port to see if TLS communication is required."

Is there any way that traefik route to the service directly ?

It is possible in nginx with the annotation : nginx.ingress.kubernetes.io/service-upstream

Is there any way to acheive this using traefik ? Or do I have to migrate to nginx ? :grin:

Thanks a lot for your help !

Hello @Stolr and thanks for your interest in Traefik,

Is there any way that traefik route to the service directly ?

This is not possible at the moment, what is the use case?

One workaround could be to use an ExternalName service which forwards the request to the Kubernetes service through its DNS name (do not miss to allow external name services as explained here, before doing this).

Hi ,

Thanks a lot for your answer.

Indeed just saw that there :

I am using ClusterMesh with Cilium. This is based on service. Since traefik does not use services I can't use the mesh feature

I'll probably switch to another ingress controller to make it possible.

Thanks a lot for your help

I am using ClusterMesh with Cilium. This is based on service. Since traefik does not use services I can't use the mesh feature

Would you mind opening a new feature request and describes the use case?

This is something that might be considered for the next Traefik version.

Sure I'll try when I have time

I need to switch all my ingresses to nginx regarding this but I'll try to find the time to do it.

Thanks for your support

Hey @Stolr,

For your interest, we opened the new feature request Allow to bypass Traefik load-balacing to use native Kubernetes load-balacing · Issue #9655 · traefik/traefik · GitHub.

Ha Ok just oppened an another one that Im going to close then ! Communication beetweek Traefik and Services · Issue #9659 · traefik/traefik · GitHub

Thanks a lot !

Regard

Hello @Stolr,

We will ship the feature you need in the next Traefik version.
You can already test it using the Release Candidate.

Could you please give it a try to check if it fits your need?

Thanks in advance for your feedback.

Hey @nicomengin

I will try to test it on a sandbox cluster and let you know.

I moved to nginx cause I really needed this feature.

Will let you know when I got time

Thanks a lot !