e0434359dd
At the moment instack-undercloud deletes all workflows with "tripleo" in the name. This has caused an issue when workflows come from other locations but shouldn't be deleted. Adding the tag allows instack-undercloud to delete only workflows with this tag. It shouldn't delete or touch workflows outside of the tripleo-common package. Parital-Bug: #1715389 Change-Id: Ieeb51f8e705b8988fb4d0f5d17d7fce6b5b04f36
69 lines
1.9 KiB
YAML
69 lines
1.9 KiB
YAML
---
|
|
version: '2.0'
|
|
name: tripleo.scale.v1
|
|
description: TripleO Overcloud Deployment Workflows v1
|
|
|
|
workflows:
|
|
|
|
delete_node:
|
|
description: deletes given overcloud nodes and updates the stack
|
|
|
|
input:
|
|
- container
|
|
- nodes
|
|
- timeout: 240
|
|
- queue_name: tripleo
|
|
|
|
tags:
|
|
- tripleo-common-managed
|
|
|
|
tasks:
|
|
|
|
delete_node:
|
|
action: tripleo.scale.delete_node nodes=<% $.nodes %> timeout=<% $.timeout %> container=<% $.container %>
|
|
on-success: wait_for_stack_in_progress
|
|
on-error: set_delete_node_failed
|
|
|
|
set_delete_node_failed:
|
|
on-success: send_message
|
|
publish:
|
|
status: FAILED
|
|
message: <% task(delete_node).result %>
|
|
|
|
wait_for_stack_in_progress:
|
|
workflow: tripleo.stack.v1.wait_for_stack_in_progress stack=<% $.container %>
|
|
on-success: wait_for_stack_complete
|
|
on-error: wait_for_stack_in_progress_failed
|
|
|
|
wait_for_stack_in_progress_failed:
|
|
on-success: send_message
|
|
publish:
|
|
status: FAILED
|
|
message: <% task(wait_for_stack_in_progress).result %>
|
|
|
|
wait_for_stack_complete:
|
|
workflow: tripleo.stack.v1.wait_for_stack_complete_or_failed stack=<% $.container %>
|
|
on-success: send_message
|
|
on-error: wait_for_stack_complete_failed
|
|
|
|
wait_for_stack_complete_failed:
|
|
on-success: send_message
|
|
publish:
|
|
status: FAILED
|
|
message: <% task(wait_for_stack_complete).result %>
|
|
|
|
send_message:
|
|
action: zaqar.queue_post
|
|
retry: count=5 delay=1
|
|
input:
|
|
queue_name: <% $.queue_name %>
|
|
messages:
|
|
body:
|
|
type: tripleo.scale.v1.delete_node
|
|
payload:
|
|
status: <% $.get('status', 'SUCCESS') %>
|
|
message: <% $.get('message', '') %>
|
|
execution: <% execution() %>
|
|
on-success:
|
|
- fail: <% $.get('status') = "FAILED" %>
|