Following examples are coded to wait till Job is completed and it pulls in console output as well. Also, it will be able to retrieve status by just looking at return code.
This can be done from FlexDeploy unix shell plugin using the command below.
Details in blue need to be updated for your setup or job being invoked.
Add necessary inputs to a FlexDeploy workflow and use the values in command below in place of INPUT1, INPUT2.
We are using JENKINS_URL, JENKINS_USERNAME, JENKINS_PASSWORD properties, which can be added to FlexDeploy workflow properties and values will be defined on Topology.