tripleo-common/undercloud_heat_plugins/__init__.py
Steve Baker 2fe97a4bf5 Override OS::Nova::Server for user_data updates
This change installs a plugin to /usr/lib/heat.
This plugin replaces the OS::Nova::Server type which is a subclass that
will not replace heat servers on stack-update when the user_data
property is changed.

heat-engine needs to be restarted to register the new plugin, so there
needs to be some mechanism to ensure this during an undercloud upgrade.
It might be possible to rely on puppet doing a service restart when
"openstack undercloud install" is run again during the upgrade. Testing
will reveal whether an explicity restart openstack-heat-engine is
needed.

Any undercloud heat can be tested for whether servers are replaced on
user_data changes by running:

  heat resource-type-show OS::Nova::Server | \
    jq '.properties.user_data.update_allowed'

The result will be 'true' when this change has been successfully
applied.

The intention is that this is backported to stable/liberty to allow
overclouds to be upgraded from kilo to liberty. This issue can be fixed
in heat for Mitaka but that heat change can't be backported to Liberty.

This will work as expected for existing overcloud stacks and their
OS::Nova::Server resouces - no resource will be replaced when
ServerUpdateAllowed becomes active.

Downstream packaging needs to do the same file copying as the setup.cfg
data_files entry, which is to copy the undercloud_heat_plugins directory
to /usr/lib/heat

Change-Id: Ibd2b70527977058d18c12ea71de7f302379c50aa
Closes-Bug: #1539541
2016-02-23 22:17:45 +00:00

0 lines
Python