From 88603fa4f741fc9ed7d0ce2109772644b2247abf Mon Sep 17 00:00:00 2001 From: Jens Langhammer Date: Tue, 1 Feb 2022 17:13:27 +0000 Subject: [PATCH] providers/proxy: set traefik labels using object_naming_template instead of UUID --- authentik/providers/proxy/controllers/docker.py | 2 +- website/docs/outposts/integrations/docker.md | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/authentik/providers/proxy/controllers/docker.py b/authentik/providers/proxy/controllers/docker.py index c58b7aaad..ef47a69de 100644 --- a/authentik/providers/proxy/controllers/docker.py +++ b/authentik/providers/proxy/controllers/docker.py @@ -23,7 +23,7 @@ class ProxyDockerController(DockerController): proxy_provider: ProxyProvider external_host_name = urlparse(proxy_provider.external_host) hosts.append(f"`{external_host_name.netloc}`") - traefik_name = f"ak-outpost-{self.outpost.pk.hex}" + traefik_name = self.name labels = super()._get_labels() labels["traefik.enable"] = "true" labels[ diff --git a/website/docs/outposts/integrations/docker.md b/website/docs/outposts/integrations/docker.md index e6fdeeae6..4c67496d1 100644 --- a/website/docs/outposts/integrations/docker.md +++ b/website/docs/outposts/integrations/docker.md @@ -23,12 +23,12 @@ The container is created with the following hardcoded properties: Additionally, the proxy outposts have the following extra labels to add themselves into traefik automatically. - `traefik.enable`: "true" - - `traefik.http.routers.ak-outpost--router.rule`: `Host(...)` - - `traefik.http.routers.ak-outpost--router.service`: `ak-outpost--service` - - `traefik.http.routers.ak-outpost--router.tls`: "true" - - `traefik.http.services.ak-outpost--service.loadbalancer.healthcheck.path`: "/akprox/ping" - - `traefik.http.services.ak-outpost--service.loadbalancer.healthcheck.port`: "9300" - - `traefik.http.services.ak-outpost--service.loadbalancer.server.port`: "9000" + - `traefik.http.routers.ak-outpost--router.rule`: `Host(...)` + - `traefik.http.routers.ak-outpost--router.service`: `ak-outpost--service` + - `traefik.http.routers.ak-outpost--router.tls`: "true" + - `traefik.http.services.ak-outpost--service.loadbalancer.healthcheck.path`: "/akprox/ping" + - `traefik.http.services.ak-outpost--service.loadbalancer.healthcheck.port`: "9300" + - `traefik.http.services.ak-outpost--service.loadbalancer.server.port`: "9000" ## Permissions