
This commit creates a new playbook to deploy both stonith for controllers and instance ha steps so that a user can drive everything by specifying just the two variables "stonith_action" and "instance_ha_action" both supporting two values "install" and "uninstall". It also sets the support for downstream releases too, for all roles, so that one can pass "liberty" or "rhos-8" arbitrarily as release parameter. Change-Id: Ia422e5e79255c0c0c1af178fc637366dc348500b
28 lines
944 B
Django/Jinja
28 lines
944 B
Django/Jinja
#!/bin/bash
|
|
|
|
set -eux
|
|
|
|
source {{ working_dir }}/environment
|
|
|
|
source {{ working_dir }}/stackrc
|
|
CONTROLLERS=$(nova list | grep controller | awk '{print $12}' | cut -f2 -d=)
|
|
CONTROLLER0=$(nova list | grep controller-0 | awk '{print $12}' | cut -f2 -d=)
|
|
|
|
{% if release in [ 'mitaka', 'rhos-9', 'newton', 'rhos-10' ] %}
|
|
# Workaround for https://bugzilla.redhat.com/show_bug.cgi?id=1348222
|
|
for CONTROLLER in $CONTROLLERS; do
|
|
$SSH heat-admin@$CONTROLLER sudo pip install redis;
|
|
done
|
|
{% endif %}
|
|
|
|
{% if release in [ 'mitaka', 'rhos-9' ] %}
|
|
# Workaround for https://bugzilla.redhat.com/show_bug.cgi?id=1357229
|
|
for CONTROLLER in $CONTROLLERS; do
|
|
$SSH heat-admin@$CONTROLLER "sudo sed -i -e 's/^After=.*/After=syslog.target network.target/g' /usr/lib/systemd/system/openstack-heat-engine.service";
|
|
done
|
|
{% endif %}
|
|
|
|
{% if release in [ 'mitaka', 'rhos-9', 'newton', 'rhos-10' ] %}
|
|
$SSH heat-admin@$CONTROLLER0 sudo pcs resource cleanup
|
|
{% endif %}
|