Merge "Only start the deploy if the Heat stack isn't already in progress"
This commit is contained in:
commit
49e14bfff5
@ -107,9 +107,11 @@ workflows:
|
|||||||
fail_workflow:
|
fail_workflow:
|
||||||
action: std.fail
|
action: std.fail
|
||||||
|
|
||||||
# Deploys a workload cloud stack
|
|
||||||
deploy_plan:
|
deploy_plan:
|
||||||
|
|
||||||
|
description: >
|
||||||
|
Deploy the overcloud for a plan.
|
||||||
|
|
||||||
input:
|
input:
|
||||||
- container
|
- container
|
||||||
- timeout: 240
|
- timeout: 240
|
||||||
@ -122,7 +124,20 @@ workflows:
|
|||||||
input:
|
input:
|
||||||
container: <% $.container %>
|
container: <% $.container %>
|
||||||
queue_name: <% $.queue_name %>
|
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:
|
deploy:
|
||||||
action: tripleo.deployment.deploy timeout=<% $.timeout %> container=<% $.container %>
|
action: tripleo.deployment.deploy timeout=<% $.timeout %> container=<% $.container %>
|
||||||
|
Loading…
Reference in New Issue
Block a user