ConsulCatalog Provider: Retrieving URL for Service

I think the question is: How - within Traefik - can I get the URL of a service (including port) registered in ConsulCatalog.

Context here is trying to setup Authelia authorization. I have registered 2 services in Consul - a service for Authelia, and a service for Traefik. Both services are in docker containers deployed by Nomad. The provider is ConsulCatalog.

As I understand it, to integrate Authelia I need to add middleware that includes the forwardAuth directive, This directive requires a direct call to the authelia service. The problem is the hostname (authelia), domain(service..local.consul) and port is recorded in ConsulCatalog, but I can't figure out how to tell Traefik to fetch this info.

Interestingly, in Traefik 1, the ConsulCatalog integration included a domain parameter which would allow one to set the domain for a query to Consul's internal DNS. That attribute is not listed in the docs for T2.

Thx in advance,


1 Like