Add workflow to generate fencing parameters
Create a workflow to supplant the need for a direct action call to generate fencing parameters. Change-Id: I63f3a579af5aa70080f8c9cdd5eb0e8f5b3d17da Partial-Bug: #1640436
This commit is contained in:
parent
89db127b44
commit
2c7fb29c16
@ -0,0 +1,5 @@
|
||||
---
|
||||
features:
|
||||
- |
|
||||
Add a workflow to generate fencing parameters so action
|
||||
tripleo.parameters.generate_fencing does not need to be called directly.
|
61
workbooks/parameters.yaml
Normal file
61
workbooks/parameters.yaml
Normal file
@ -0,0 +1,61 @@
|
||||
---
|
||||
version: '2.0'
|
||||
name: tripleo.parameters.v1
|
||||
description: TripleO Parameter-related Workflows
|
||||
|
||||
workflows:
|
||||
generate_fencing_parameters:
|
||||
description: >
|
||||
This workflow will generate fencing parameters from the given inputs for
|
||||
a deployment.
|
||||
input:
|
||||
- nodes_json
|
||||
- os_auth
|
||||
- fence_action
|
||||
- delay
|
||||
- ipmi_level
|
||||
- ipmi_cipher
|
||||
- ipmi_lanplus
|
||||
- queue_name: tripleo
|
||||
|
||||
tags:
|
||||
- tripleo-common-managed
|
||||
|
||||
output:
|
||||
fencing_parameters: <% $.get('fencing_parameters', {}) %>
|
||||
|
||||
tasks:
|
||||
generate_fencing_params:
|
||||
action: tripleo.parameters.generate_fencing
|
||||
input:
|
||||
nodes_json: <% $.nodes_json %>
|
||||
os_auth: <% $.os_auth %>
|
||||
fence_action: <% $.fence_action %>
|
||||
delay: <% $.delay %>
|
||||
ipmi_level: <% $.ipmi_level %>
|
||||
ipmi_cipher: <% $.ipmi_cipher %>
|
||||
ipmi_lanplus: <% $.ipmi_lanplus %>
|
||||
on-complete: notify_zaqar
|
||||
publish:
|
||||
fencing_parameters: <% task().result %>
|
||||
status: SUCCESS
|
||||
message: 'Fencing parameters successfully generated'
|
||||
publish-on-error:
|
||||
status: FAILED
|
||||
message: <% task().result %>
|
||||
|
||||
notify_zaqar:
|
||||
action: zaqar.queue_post
|
||||
input:
|
||||
queue_name: <% $.queue_name %>
|
||||
messages:
|
||||
body:
|
||||
type: tripleo.parameters.v1.generate_fencing_parameters
|
||||
payload:
|
||||
status: <% $.status %>
|
||||
message: <% $.get('message', '') %>
|
||||
execution: <% execution() %>
|
||||
fencing_parameters: <% $.get('fencing_parameters', {}) %>
|
||||
on-success:
|
||||
- fail: <% $.get('status') = "FAILED" %>
|
||||
|
Loading…
Reference in New Issue
Block a user