I have a local text file in windows, it contains multiple shell commands to run on a remote Unix box using putty. The whole process is controlled in groovy script of soap.
Groovy Script, trying to run it ..
def command = "C:/Program Files (x86)/PuTTY/putty.exe -ssh ******@****** -pw ***** -m C:/Users/script/aa.txt" def Process p = Runtime.getRuntime().exec(command);
As you see puuty is open with user , pass properly
sudo su - dev1b /work/id852100/auto.sh
Then it is calling sudo , but not coming out of the command ..so next command also not running.
If I use
-t as interactive and just finishing sudo properly , not running next. I want both commands run automatically. Can you suggest how to keep commands in the local file and any mistake in groovy script