I would like to map all my controllers under a context path called /network, but my Actuator path under /actuator. I've attempted the following configuration in my application.properties, but the actuator path becomes /network/actuator, instead of /actuator:
server.servlet.context-path=/network
management.endpoints.web.base-path=/actuator
I've tried using the (deprecated) management.server.servlet.context-path property too, but this resulted in the same issue.
As a workaround, I can annotate my controllers with @RequestMapping, but it would be great if I can use the context path instead. I'm using Spring Boot 3.0.6.
You can try to use such approach with separate configuration for this purpose: