From 31ce7fc48e153eef96250b50b2513052f00bd488 Mon Sep 17 00:00:00 2001 From: Piotr Biernat Date: Sat, 20 Jul 2024 14:42:16 +0200 Subject: [PATCH] tls fix --- consul/discovery.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/consul/discovery.go b/consul/discovery.go index 2e2b4a9..bb04d53 100644 --- a/consul/discovery.go +++ b/consul/discovery.go @@ -17,6 +17,7 @@ type Service struct { appID string domain string pathPrefix string + tls bool port int ttl time.Duration client *consul.Client @@ -37,6 +38,7 @@ func NewService(servAddr, id, name, useDomainOverIp, addr, domain, pathPrefix st s.appID = id s.domain = domain s.pathPrefix = pathPrefix + s.tls = true // FIXME add arg s.port = appPort s.ttl = time.Second * 10 @@ -215,8 +217,8 @@ func (s *Service) getTags() []string { "traefik.http.services." + s.Name + ".loadbalancer.healthcheck.interval=1s", "traefik.http.services." + s.Name + ".loadbalancer.healthcheck.timeout=1s", "traefik.http.services." + s.Name + ".loadbalancer.healthcheck.path=/health", - "traefik.tls.certificates.certfile=/certs/client.cert", - "traefik.tls.certificates.keyfile=/certs/client.key", + "traefik.tls.certificates.certfile=certs/client.cert", + "traefik.tls.certificates.keyfile=certs/client.key", } return tags