Merge "Only start the deploy if the Heat stack isn't already in progress"

This commit is contained in:
Jenkins 2017-01-17 14:52:45 +00:00 committed by Gerrit Code Review
commit 49e14bfff5

View File

@ -107,9 +107,11 @@ workflows:
fail_workflow:
action: std.fail
# Deploys a workload cloud stack
deploy_plan:
description: >
Deploy the overcloud for a plan.
input:
- container
- timeout: 240
@ -122,7 +124,20 @@ workflows:
input:
container: <% $.container %>
queue_name: <% $.queue_name %>
on-complete: deploy
on-complete: get_heat_stack
get_heat_stack:
action: heat.stacks_get stack_id=<% $.container %>
on-error: deploy
on-success:
- set_stack_in_progress: <% "_IN_PROGRESS" in task(get_heat_stack).result.stack_status %>
- deploy: <% not "_IN_PROGRESS" in task(get_heat_stack).result.stack_status %>
set_stack_in_progress:
on-success: send_message
publish:
status: FAILED
message: The Heat stack is busy.
deploy:
action: tripleo.deployment.deploy timeout=<% $.timeout %> container=<% $.container %>