From c11395cbd660988ccb70eac69703910cff3df988 Mon Sep 17 00:00:00 2001 From: Pascal Bruckert Date: Mon, 23 Dec 2024 22:06:35 +0100 Subject: [PATCH] fix Django Admin with traefik --- docker-compose-traefik.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docker-compose-traefik.yaml b/docker-compose-traefik.yaml index c6ebcf7..6fb2f03 100644 --- a/docker-compose-traefik.yaml +++ b/docker-compose-traefik.yaml @@ -39,7 +39,7 @@ services: labels: - "traefik.enable=true" - "traefik.http.routers.adventurelogweb.entrypoints=websecure" - - "traefik.http.routers.adventurelogweb.rule=Host(`yourdomain.com`) && !PathPrefix(`/media`)" # Replace with your domain + - "traefik.http.routers.adventurelogweb.rule=Host(`yourdomain.com`) && !(PathPrefix(`/media`) || PathPrefix(`/admin`) || PathPrefix(`/static`))" # Replace with your domain - "traefik.http.routers.adventurelogweb.tls=true" - "traefik.http.routers.adventurelogweb.tls.certresolver=letsencrypt" @@ -64,7 +64,7 @@ services: labels: - "traefik.enable=true" - "traefik.http.routers.adventurelogserver.entrypoints=websecure" - - "traefik.http.routers.adventurelogserver.rule=Host(`yourdomain.com`) && PathPrefix(`/media`)" # Replace with your domain + - "traefik.http.routers.adventurelogserver.rule=Host(`yourdomain.com`) && && (PathPrefix(`/media`) || PathPrefix(`/admin`) || PathPrefix(`/static`))" # Replace with your domain - "traefik.http.routers.adventurelogserver.tls=true" - "traefik.http.routers.adventurelogserver.tls.certresolver=letsencrypt"