Traefik Routing

I am running 2x frontends (frontend1 & frontend2) on same url. While accessing the frontend header pass through X-Branch-Code = null. I want to re-route users to frontend2 while passing their X-Branch-Code value and those without X-Branch-Code will be redirected to frontend 1.

Any help will be much appreciated.


With rule you can check not only for Host, but also for headers. So you could set up multiple routers.