/** * Execute a shell command on a remote vm * * @param vmIpAddress remote vm ip address * @param userName user name * @param password password * @param command shell command */ public void executeCommand(String vmIpAddress, String userName, String password, String command) { SSHExec sshExec = new SSHExec(); sshExec.setUsername(userName); sshExec.setPassword(password); sshExec.setHost(vmIpAddress); sshExec.setCommand(command); sshExec.setProject(PROJECT); sshExec.setTrust(true); log.info("Executing command: {}, on {}", command, vmIpAddress); sshExec.execute(); }