Explicitly set java home in CommandLineInvoker
See gh-20242
This commit is contained in:
committed by
Stephane Nicoll
parent
e73ee7b3fe
commit
e66758d3d0
@@ -76,6 +76,7 @@ public final class CommandLineInvoker {
|
||||
command.addAll(Arrays.asList(args));
|
||||
ProcessBuilder processBuilder = new ProcessBuilder(command).directory(this.workingDirectory);
|
||||
processBuilder.environment().put("JAVA_OPTS", "-Duser.home=" + this.temp);
|
||||
processBuilder.environment().put("JAVA_HOME", System.getProperty("java.home"));
|
||||
return processBuilder.start();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user