tripleo-common/doc/source/tripleo-mistral.rst
Dougal Matthews cfed296ced Remove the old, deprecated Mistral action names
These have never been in a stable release of TripleO and can be
safely removed.

Closes-Bug: #1625641
Depends-On: I045ddfe9aee6c40138b9080fc65785159c6ea6eb
Depends-On: I3f5f63751503ece0db9d703f28e9720011e81a1b
Change-Id: If7919b9d76cd03a62b5cd8dc925f42e68224ae85
2016-09-23 09:45:11 +01:00

2.4 KiB

TripleO and Mistral

TripleO is in the process of developing Mistral workflows and actions to expose TripleO business logic. This allows RESTful API access to TripleO functions.

A high-level view of the overall workflow can be found in the TripleO Overcloud Deployment Library Spec.

Undercloud Setup

To install the undercloud follow the TripleO developer documentation.

Code Location

The relevant code is organized as below. Note that Mistral actions are exposed through setup.cfg.

tripleo-common/
 |
 + setup.cfg
 |
 + tripleo_common/
    |
    + actions/
 |
 + workbooks/

Using Actions

Mistral actions can be run through the CLI:

echo '{"container": "<container-name>"}' > input.json
openstack action execution run tripleo.plan.create_container input.json

For REST API usage please reference the full Mistral documentation.

Using Workflows

The undercloud install will automatically load the TripleO Mistral workbooks. To manually load these workbooks during development, run the following:

openstack workbook create workbooks/plan_management.yaml

Workflow execution is asynchronous. The output of an execution is an ID that can be used to get the status and output of that workflow execution.

echo '{"container": "<container-name>"}' > input.json
openstack workflow execution create tripleo.plan_management.v1.create_default_deployment_plan input.json
openstack workflow execution show <execution ID>
openstack workflow execution show output <execution ID>

For REST API usage please reference the full Mistral documentation.

By default a workflow execution expires after 48 hours. This can be configured in /etc/mistral/mistral.conf.

[execution_expiration_policy]
evaluation_interval=120
older_than=2880

After modifying these values you will need to restart the mistral-engine service.