spring-boot-admin icon indicating copy to clipboard operation
spring-boot-admin copied to clipboard

Public URL is resolves to wrong base url

Open michael-wirth opened this issue 5 years ago • 0 comments

Spring Boot Admin 2.4.1

The Spring Boot Admin is accessible through a WAF with public URL: https://myhost:443/app/admin The application itself is using a context-path: /admin because it is deployed to a web application server as web archive.

The public URL is configured via spring configuration: spring.boot.admin.ui.public-url=https://myhost:443/app/admin

The combination of the public URL and the context path resolve to: https://myhost:443/admin/app/admin. -> <context-path>/<public-path>, which is wrong

If I define a public URL why is it merged in the UiController.getBaseUrl() method? I'd like to use the public URL as IS and not have it modified for unknown reasons.

There is a workaround by defining the public URL as https://myhost:443/../app/admin which will resolve to: <base href="https://myhost:443/admin/../app/admin/">

That is working but an ugly solution.

michael-wirth avatar May 02 '21 10:05 michael-wirth