Skip to content

Commit cf85144

Browse files
committed
feat(huntarr): Implement Traefik middleware configurations for Huntarr service
1 parent fe02ede commit cf85144

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

docker-compose.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,8 @@ services:
370370
- PUID=${USER_ID}
371371
- PGID=${GROUP_ID}
372372
- TZ=${TIMEZONE}
373-
- BASE_URL=/huntarr
373+
# Not using Huntarr's base URL feature until this is merged: https://github.com/plexguide/Huntarr.io/pull/760
374+
# - BASE_URL=/huntarr
374375
volumes:
375376
- ${CONFIG_ROOT:-.}/huntarr:/config
376377
labels:
@@ -379,6 +380,12 @@ services:
379380
- traefik.http.routers.huntarr.tls=true
380381
- traefik.http.routers.huntarr.tls.certresolver=myresolver
381382
- traefik.http.services.huntarr.loadbalancer.server.port=9705
383+
- traefik.http.middlewares.huntarr-slash.redirectregex.regex=^https?://([^/]+)/huntarr$
384+
- traefik.http.middlewares.huntarr-slash.redirectregex.replacement=https://$${1}/huntarr/
385+
- traefik.http.middlewares.huntarr-slash.redirectregex.permanent=true
386+
- traefik.http.middlewares.huntarr-strip.stripprefix.prefixes=/huntarr
387+
- traefik.http.middlewares.huntarr-xfp.headers.customrequestheaders.X-Forwarded-Prefix=/huntarr
388+
- traefik.http.routers.huntarr.middlewares=huntarr-slash,huntarr-strip,huntarr-xfp
382389
- homepage.group=Download
383390
- homepage.name=Huntarr
384391
- homepage.icon=huntarr.png

0 commit comments

Comments
 (0)