Open Hypercookie opened 1 month ago
Experiencing the same issue when switching to traefik v3.
I'm also getting the same issue.
One inconvenient workaround (FYI, I am using Portainer to manage my docker containers/stacks), is to go to the container that was automatically created via outposts, duplicate/edit the container, click on Labels, and then edit the router rule.
e.g.
(Host(`a.domain.tld`) || Host(`b.domain.tld`)) && PathPrefix(`/outpost.goauthentik.io`)
Found the code in the repo that would need to be updated:
authentik/providers/proxy/controllers/docker.py:get_labels:Line:~31
labels[f"traefik.http.routers.{traefik_name}-router.rule"] = (
f"Host({','.join(hosts)}) && PathPrefix(`/outpost.goauthentik.io`)"
)
Something along the lines of the following:
labels[f"traefik.http.routers.{traefik_name}-router.rule"] = (
f"({' || '.join([f'Host(`{host}`)' for host in hosts])}) && PathPrefix(`/outpost.goauthentik.io`)"
)
I'm also getting the same issue. One inconvenient workaround (FYI, I am using Portainer to manage my docker containers/stacks), is to go to the container that was automatically created via outposts, duplicate/edit the container, click on Labels, and then edit the router rule.
![]()
![]()
e.g. (Host(
a.domain.tld
) || Host(b.domain.tld
)) && PathPrefix(/outpost.goauthentik.io
)
Thanks for this. That worked good.
Wondering if I can just add the authentik/proxy image to my docker-compose and set it up manually myself so that I can bring it up / down without needing to edit the label in portainer.
Would you be willing to open a PR for this?
I'll try and see if I can. I'll have to set an environment up. Thanks.
Describe the bug When deploying a proxy outpost labels are added automatically which add the outpost to Traefik. For each
single-forward
provider aHost(<host>)
label has to be used. Authentik generates these asHost(<host>, <host>, ...)
which is not possible anymore since Traefik v3.0 (See here and here). This leads to an invalid deployment of the outpost which makes it defacto unusable for users with Traefik >v3.0 since the label can not be disabled as far as I can tell.To Reproduce Deploy a proxy outpost with multilple providers on a system with Traefik > v3.0 which uses the docker label integration
Expected behavior Authentik should generate a valid label.
Logs
"error while adding rule Host(`<redacted>`,`<redacted>`,`<redacted>`) && PathPrefix(`/outpost.goauthentik.io`): error while adding rule and: error while adding rule Host: unexpected number of parameters; got 3, expected one of [1]"
Version and Deployment (please complete the following information):