From fa4c50301c559a39d8a8068477c285ec40c6bf5e Mon Sep 17 00:00:00 2001 From: surtur Date: Mon, 17 Jan 2022 10:29:43 +0100 Subject: [PATCH] fix: inaccessible tags --- docker-compose.yml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/docker-compose.yml b/docker-compose.yml index c954d21..57e297b 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -24,6 +24,18 @@ services: - traefik.enable=true - traefik.http.services.homepage.loadbalancer.server.port=80 - traefik.http.routers.homepage.rule=Host(`localhost`) || Host(`127.0.0.1`) || Host(`homepage`) || Host(`6426tqrh4y5uobmo5y2csaip3m3avmjegd2kpa24sadekpxglbm34aqd.onion`) + # ref: https://stackoverflow.com/a/61976953 + # ref: https://github.com/traefik/traefik/issues/563 + - "traefik.http.routers.homepage.middlewares=homepage-redirectregex, homepage-replacepathregex" + + - "traefik.http.middlewares.homepage-replacepathregex.replacepathregex.regex=^/tags/(.*)$$" + - "traefik.http.middlewares.homepage-replacepathregex.replacepathregex.replacement=https://dotya.ml/tags/$$1/" + - "traefik.http.middlewares.homepage-redirectregex.redirectregex.regex=^/tags$$" + - "traefik.http.middlewares.homepage-redirectregex.redirectregex.replacement=https://dotya.ml/tags/" + - "traefik.frontend.redirect.regex=^https://dotya.ml/tags/(.*)$$" + - "traefik.frontend.redirect.replacement=https://dotya.ml/tags/$$1/" + - "traefik.frontend.rule=PathPrefix:/tags;ReplacePathRegex: ^/tags/(.*) /tags/$$1/" + logging: driver: json-file options: