Sample Header Ad - 728x90

How to pass Command to program open in shell?

1 vote
1 answer
2788 views
I am writing a shell script to auto-deploy a program with Jboss-cli, in linux ubuntu. I need to open the jboss cli interface and execute some commands but I want to do this automatically. what it looks like cd /opt/jboss/bin ./jboss-cli.sh --connect the above line open the jboss command line. I would like to be able to send a command to the open program like: undeploy FlcErp.ear I've tried to echo it and give it straight text but nothing will execute until the Jboss program is done running. I've also tried ./jboss-cli.sh --connect undeploy "FlcErp.ear" but It reads "FlcErp.ear" as a command
Asked by Sam Orozco (113 rep)
Sep 22, 2016, 07:55 PM
Last activity: Jul 23, 2018, 02:28 PM