From 82cc1d536a67131a62384cd74bd9ba7637b15fe3 Mon Sep 17 00:00:00 2001 From: Jens Langhammer Date: Sun, 23 Jan 2022 21:55:44 +0100 Subject: [PATCH] providers/proxy: add PathPrefix to auto-traefik labels Signed-off-by: Jens Langhammer #2128 --- authentik/providers/proxy/controllers/docker.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/authentik/providers/proxy/controllers/docker.py b/authentik/providers/proxy/controllers/docker.py index 298f0ac0f..c59673676 100644 --- a/authentik/providers/proxy/controllers/docker.py +++ b/authentik/providers/proxy/controllers/docker.py @@ -26,7 +26,9 @@ class ProxyDockerController(DockerController): traefik_name = f"ak-outpost-{self.outpost.pk.hex}" labels = super()._get_labels() labels["traefik.enable"] = "true" - labels[f"traefik.http.routers.{traefik_name}-router.rule"] = f"Host({','.join(hosts)})" + labels[ + f"traefik.http.routers.{traefik_name}-router.rule" + ] = f"Host({','.join(hosts)}) && PathPrefix('/akprox')" labels[f"traefik.http.routers.{traefik_name}-router.tls"] = "true" labels[f"traefik.http.routers.{traefik_name}-router.service"] = f"{traefik_name}-service" labels[