If we apply a rolling deployment, that is in charge of setting up the appropriate tag (for example using hashicorp nomad) we will for some time (depending on how fast the deployment is etc) have two tags on the same service in consul that matches traefik.http.router.example.rule.
This will result in the following error:
Router defined multiple times with different configurations in [xxxx]
This ofc is expected to have given the circumstances.
The problem is that traefik will remove the route all together.
Is this by design?
I would like traefik to be able to handle this situation by choosing one of the routes. Preferably the old until the old is gone.
+1 We are getting "Router defined multiple times with different configurations in" all the time, even just updating the current service docker-compose file.
So we use consul. Traefik has both the consulCatalog and the consul K/V provider.
Our solution will be:
Our routes will be defined using consulCatalog. To circumvent duplicates we will make sure that the routes will always be unique by adding a hash in the name and let our pipeline handle creation of these routes.
Our middlewares will be defined using consul K/V, which ofc resolve the problem about duplicate middleware names.