From cefea119eddcf7eefeb177d13fb11b3e9ea4f14c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Menou?= Date: Wed, 28 Mar 2018 10:14:55 +0200 Subject: Fix typo --- files/clever-wait-deploy.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/files/clever-wait-deploy.sh b/files/clever-wait-deploy.sh index 99088cc..c955f6a 100644 --- a/files/clever-wait-deploy.sh +++ b/files/clever-wait-deploy.sh @@ -32,7 +32,7 @@ function check { done # Wait for completion - echo "Deployement in progress..." + echo "Deployment in progress..." while deploying "$commit" -a $timeout -gt 0 do sleep $samplingTime -- cgit v1.2.3 From d7d8a988fe5640c5ffa01e1e690516cd201665a5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Menou?= Date: Fri, 30 Mar 2018 16:38:27 +0200 Subject: Watch and wait for Clever --- tasks/deploy.yml | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/tasks/deploy.yml b/tasks/deploy.yml index 8b98d8c..54c04ac 100644 --- a/tasks/deploy.yml +++ b/tasks/deploy.yml @@ -24,7 +24,19 @@ - name: Push to Clever-Cloud to trigger deployment command: "git push --force git+ssh://git@push-par-clevercloud-customers.services.clever-cloud.com/{{ clever_app }}.git HEAD:refs/heads/master" -- name: Wait until deployment completion +- name: Watch deployment status command: clever-wait-deploy.sh + async: 900 + poll: 0 + register: long_command environment: CONFIGURATION_FILE: "{{ clever_login_file }}" + +# Waits up to 15 minutes +- name: Wait for deployment completion + async_status: + jid: "{{ long_command.ansible_job_id }}" + register: job_result + until: job_result.finished + delay: 30 + retries: 30 -- cgit v1.2.3