Trying to use Traefik to prettify (+TLS) a jboss app server. Server runs at ip:8080/path/login
Following config (ignore the extra stuff, just playing around with what might work) works great if I go to sub.domain.com I get the page at ip:8080 displayed. If I manually go to sub.domain.com/path/login I get the login.
How can I use traefik to automatically display ip:8080/path/login at sub.domain.com?
This functionality used to exist in v1 https://gist.github.com/kekru/d088be6a3fa844089ae62d80c077bb38 and worked great. In v2 it results in missing assets (due to the relative assets trying to load over http vs https).
[http.routers.app]
rule = "Host(`sub.domain.com`)"
service = "app"
# middlewares = ["add-app-prefix"]
entrypoint = ["websecure"]
[http.routers.app.tls]
certresolver = "letsencrypt"
[http.services]
[http.services.app.loadbalancer]
[[http.services.app.loadbalancer.servers]]
url = "http://app-app-prd:8080"
[http.middlewares]
[http.middlewares.add-app-prefix.addPrefix]
prefix = "/path/"
[http.middlewares.add-app-path.stripPrefix]
path = "/path/login"
[http.middlewares.add-app-redirect.redirectRegex]
regex = "^http://app-prd:8080/(.*)"
replacement = "https://sub.domain.com/${1}"