332780222e
In an attempt to move blocking on the stack moving back to a COMPLETE or FAILED state out of the client and into the workflows, here is a utility workflow to do just that. First user will be the node delete workflow. Also add a workflow for waiting for a stack to go to IN_PROGRESS. Change-Id: Ibbb359de8a873ee76b0e274e631307d4e4804fca
37 lines
1.0 KiB
YAML
37 lines
1.0 KiB
YAML
---
|
|
version: '2.0'
|
|
name: tripleo.stack.v1
|
|
description: TripleO Stack Workflows
|
|
|
|
workflows:
|
|
|
|
wait_for_stack_complete_or_failed:
|
|
input:
|
|
- stack
|
|
- timeout: 14400 # 4 hours. Default timeout of stack deployment
|
|
|
|
tasks:
|
|
|
|
wait_for_stack_status:
|
|
action: heat.stacks_get stack_id=<% $.stack %>
|
|
timeout: <% $.timeout %>
|
|
retry:
|
|
delay: 15
|
|
count: <% $.timeout / 15 %>
|
|
continue-on: <% task(wait_for_stack_status).result.stack_status in ['CREATE_IN_PROGRESS', 'UPDATE_IN_PROGRESS'] %>
|
|
|
|
wait_for_stack_in_progress:
|
|
input:
|
|
- stack
|
|
- timeout: 600 # 10 minutes. Should not take much longer for a stack to transition to IN_PROGRESS
|
|
|
|
tasks:
|
|
|
|
wait_for_stack_status:
|
|
action: heat.stacks_get stack_id=<% $.stack %>
|
|
timeout: <% $.timeout %>
|
|
retry:
|
|
delay: 15
|
|
count: <% $.timeout / 15 %>
|
|
continue-on: <% task(wait_for_stack_status).result.stack_status in ['CREATE_COMPLETE', 'CREATE_FAILED', 'UPDATE_COMPLETE', 'UPDATE_FAILED'] %>
|