Spring Boot 2 health actuator default mapping

Viewed 19833

I'm using Spring Boot 2 M3 actuators. By default, the health endpoint is mapped to /application/health.

  • Is it possible to change this path to /health?
4 Answers

In your application.properties file add this to set the base path to '/'

management.endpoints.web.base-path=/

Path will now be '/health'

Edit: Alternatively if you are using YAML use:

management:
  endpoints:
    web:
      base-path: /
Related