If you are reviewing the use of JAVA_HOME, perhaps you can also consider the overall JAVA usage and review : Sonar.sh CMDJAVA loop issue ? When I raised that issue, it was more “does not work”, while now thoughts are also why is it not using JAVA_HOME?