From 79f6584fa98a02fceb779cd6efbaf8c7a61add81 Mon Sep 17 00:00:00 2001 From: Anthony Lin Date: Tue, 31 Oct 2017 22:40:06 +0000 Subject: [PATCH] Update deploy_site.sh script with exit codes It is noted during integration testing that we should have an exit code for the script. This is needed in order for us to know the final state of the workflow and to decide whether it was successful or not. Change-Id: I1f0b2a357d89fc3e898db68b930ada02b52ab398 --- tools/deploy_site.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/tools/deploy_site.sh b/tools/deploy_site.sh index e525c9db..4dfa9317 100755 --- a/tools/deploy_site.sh +++ b/tools/deploy_site.sh @@ -108,3 +108,11 @@ done # Delete the temporary files rm /tmp/deploy_site_response.json rm /tmp/get_action_status.json + +# Return exit code so that we can use it to determine the final +# state of the workflow +if [[ $action_lifecycle == "Complete" ]]; then + exit 0 +else + exit 1 +fi