In same cases deployment tasks include execution of scripts that required user inputs through interactive prompts during the script execution.
The following example can assist you automate similar scenarios:
Assuming I have deployment script name "interactive.sh" which include 2 interactive questions:
1.Confirmation for program installation
2.Program installation path
Example for manual installation:
In CA RA you can use run command line action and pass the user input using echo command (\\n use for new line sequence)
Hi Jacky, i am using a script where there are some menu driven steps in a script.. like
need to execute option 4 and 9 .. in a sequence ..
using printf "3/n9"|./test.sh command..
while running this command on ksh shell ,..mouse is continuously scrolling up and down and not to quit from script.
That's neat, Jacky. I didn't know that. Another trick, which I'm not sure how reliable it is for use in production, might be to use/call an expect script.
Based on the suggestion above I believe you would maybe need to try and run (should be able to confirm by doing it manually on a machine before trying it in RA): echo "4\\n9\\n" | printf "3/n9" | ./test.sh
I wonder if the printf "3/n9" portion of your command is used to specify option 3 and then 9. If so and it isn't working then maybe try it with: echo "3\\n9\\n" | ./test.sh
You can use expect command but its not part of the OS by default and required to write some scripts.