Runnable Spring Boot JAR + Docker: Enable JMX
When you run a Spring Boot app in a Docker container, you can’t access JMX endpoints using the basic config.
Command to use to start your Spring Boot application inside your Docker container:
Then you just have to map the port 8089 in a port of your host machine (let’s say 8089), and you can access it via Visual VM at “localhost:8089”.