From 5dcd27e8b894e5b34e59670f3a7ac71a792c8c86 Mon Sep 17 00:00:00 2001 From: Piotr Biernat Date: Mon, 15 Jul 2024 20:10:06 +0200 Subject: [PATCH] Update traefik router tag --- consul/discovery.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/consul/discovery.go b/consul/discovery.go index 1987bec..3b2f7c4 100644 --- a/consul/discovery.go +++ b/consul/discovery.go @@ -178,7 +178,8 @@ func (s *Service) healthCheck() (bool, error) { func (s *Service) getTags() []string { tags := []string{ "traefik.enable=true", - "traefik.http.routers." + s.Name + ".rule=PathPrefix(`" + s.pathPrefix + "`)", + // "traefik.http.routers." + s.Name + ".rule=PathPrefix(`" + s.pathPrefix + "`)", + "traefik.http.routers." + s.Name + ".rule=Host(`" + s.domain + "`)", "traefik.http.routers." + s.Name + ".entryPoints=https", // "traefik.http.routers." + s.Name + ".tls=true", "traefik.http.routers." + s.Name + ".service=" + s.Name,