File tree Expand file tree Collapse file tree 4 files changed +25
-43
lines changed
Expand file tree Collapse file tree 4 files changed +25
-43
lines changed Original file line number Diff line number Diff line change @@ -19,6 +19,13 @@ if [ -z "$workflow_created" ]; then
1919 exit 0
2020fi
2121
22+ # Check that the instance URL exists
23+ instance_url=$( cat config/INSTANCE_URL)
24+ if [ -z " $instance_url " ]; then
25+ echo " No instance URL found. Please run the trigger workflow script first."
26+ exit 1
27+ fi
28+
2229# Step 1: Obtain your OAuth token
2330# Note: Substitute these values with your own
2431ACCESS_TOKEN=$( cat config/ds_access_token.txt)
@@ -167,6 +174,24 @@ echo ""
167174echo " Use this URL to complete the workflow steps:"
168175echo $decoded_instance_url
169176
177+ sleep 5
178+
179+ # ds-snippet-start:Maestro1Step6
180+ # [Optional] Launch local server and embed workflow instance using the instance URL
181+ decoded_instance_url=$( echo " $instance_url " | sed ' s/\\u0026/\&/g' )
182+
183+
184+ host_url=" http://localhost:8080"
185+ if which xdg-open & > /dev/null ; then
186+ xdg-open $host_url
187+ elif which open & > /dev/null ; then
188+ open $host_url
189+ elif which start & > /dev/null ; then
190+ start $host_url
191+ fi
192+ php ./examples/Maestro/lib/startServerForEmbeddedWorkflow.php " $decoded_instance_url "
193+ # ds-snippet-end:Maestro1Step6
194+
170195# Remove the temporary files
171196rm " $request_data "
172197rm " $response "
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 3434 </style>
3535 </head>
3636 <body>
37- #ds-snippet-start:Maestro2Step3
3837 <div>
3938 <iframe src= $ triggerUrl width=800 height=600>
4039 </iframe>
4140 </div>
42- #ds-snippet-end:Maestro2Step3
4341 </body>
4442 </html>
4543
Original file line number Diff line number Diff line change @@ -968,21 +968,15 @@ function startMaestro() {
968968 PS3=' Select the action : '
969969 select CHOICE in \
970970 " Trigger_Workflow" \
971- " Embed_Workflow" \
972971 " Home" ; do
973972 case " $CHOICE " in
974-
975973 Home)
976974 choices
977975 ;;
978976 Trigger_Workflow)
979977 bash examples/Maestro/eg001TriggerWorkflow.sh
980978 startMaestro
981979 ;;
982- Embed_Workflow)
983- bash examples/Maestro/eg002EmbedWorkflow.sh
984- startMaestro
985- ;;
986980 * )
987981 echo " Default action..."
988982 startMaestro
You can’t perform that action at this time.
0 commit comments