Skip to content

Commit 01adf35

Browse files
committed
add connect all execute to orchestrator
1 parent 49d3042 commit 01adf35

1 file changed

Lines changed: 15 additions & 1 deletion

File tree

orchestration_service/orchestrator.py

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,10 @@ def execute_app_orchestration():
3030
[AttributeNameValue("VM_UUID", deployment_result.VmUuid),
3131
AttributeNameValue("Cloud Provider", deployment_result.CloudProviderResourceName)])])
3232

33-
# logical resource execute "Power On"
33+
# connect all
34+
connect_all(api, reservation_id)
35+
36+
# "Power On"
3437
power_on_deployed_app(api, app_name, deployment_result, reservation_id)
3538

3639
# if install service exists on app execute it
@@ -45,6 +48,17 @@ def execute_app_orchestration():
4548
logger.info("Deployed {0} Successfully".format(app_name))
4649

4750

51+
def connect_all(api, reservation_id):
52+
try:
53+
api.ExecuteEnvironmentCommand(reservation_id, "Connect All")
54+
except CloudShellAPIError as exc:
55+
logger.error("Error executing connect all. Error: {0}".format(exc.rawxml))
56+
exit(1)
57+
except Exception as exc:
58+
logger.error("Error executing connect all. Error: {0}".format(str(exc)))
59+
exit(1)
60+
61+
4862
def refresh_ip(api, deployment_result, reservation_id):
4963
logger.info("Waiting to get IP for deployed app resource {0}...".format(deployment_result.LogicalResourceName))
5064
try:

0 commit comments

Comments
 (0)