Prepare packages:
$ sudo apt-get install python-dev python-setuptools python-pip libffi-dev libxslt1-dev libxml2-dev libyaml-dev libssl-dev$ cd ~$ git clone https://github.com/openstack/mistral.git$ git clone https://github.com/gryf/mistral-evacuate.git$ cd mistral$ git checkout –b stable/mitaka origin/stable/mitaka$ cp ~/mistral-evacuate/filter_vm_action.py ./$ cp ~/mistral-evacuate/evacuate_vm_action.py ./$ tox -egenconfig
append lines in mistral/setup.cfg if you have some customed actions for mistral:
[entry_points]mistral.actions =…custom.filter_vm = filter_vm_action:FilterVmActioncustom.evacuate = evacuate_vm_action:EvacuateVmAction
generate mistral.conf
$ cd ~/mistral$ oslo-config-generator --config-file tools/config/config-generator.mistral.conf --output-file etc/mistral.conf
add following lines in mistral.conf:
[DEFAULT]logfile = /opt/stack/logs/mistral.logrpc_backend = rabbit[database]connection = mysql+pymysql://root:@controller:3306/mistral[keystone_authtoken]auth_uri = http://controller:5000/v3identity_uri = http://controller:35357/auth_version = v3admin_user = adminadmin_password = admin_tenant_name = admin[oslo_messaging_rabbit]rabbit_userid = stackrabbitrabbit_password = rabbit_host = controller
register mistral service and endpoints on keystone:
$ . admin-openrc$ MISTRAL_URL = “http://172.16.13.40:8989/v2”$ openstack service create workflow --name mistral --description 'OpenStack Workflow service'$ openstack endpoint create workflow --region RegionOne --publicurl $MISTRAL_URL --adminurl $MISTRAL_URL --internalurl $MISTRAL_URL
create mysql database mistral:
mysql -u root -pCREATE DATABASE mistral;USE mistralGRANT ALL ON mistral.* TO ‘root’@’%’;
Local installation and prepare database:
$ cd ~/mistral$ sudo pip install –e .$ mistral-db-manage --config-file etc/mistral.conf upgrade head$ mistral-db-manage --config-file etc/mistral.conf populate
start mistral service:
# python mistral/cmd/launch.py --server all --config-file etc/mistral.conf