Set ServerDeletionPolicy during upgrade prepare and converge

This change will always set ServerDeletionPolicy to 'retain' during
upgrade prepare, and back to the default 'delete' during the converge.

For a normal upgrade this will have no effect since scale-down is not
recommended during an upgrade.

For a transition from nova based undercloud to nova-less, this allows
the following steps to work:
1. operator builds a valid deployed-server environment file by running
   'openstack overcloud node extract provisioned'[1]
2. running 'openstack overcloud upgrade prepare' will prevent the next
   stack update from deleting any nova servers
3. running 'openstack overcloud upgrade converge' with the environment
   from 1. will replace nova heat resources with deployed server
   resources which are managed directly with the provision/unprovision
   commands

This approach is an alternative to preventing the heat nova resource
from ever deleting a nova server after the undercloud upgrade[2]

[1] https://review.opendev.org/#/c/674141/
[2] https://review.opendev.org/#/c/675498/
Blueprint: bp/nova-less-deploy

Change-Id: I0bca04cd4883a1bf61b06a0828e323bc388a95be
This commit is contained in:
Steve Baker 2019-11-05 08:56:49 +13:00
parent ad27bcc3ea
commit ab958c2f3e
2 changed files with 2 additions and 0 deletions

View File

@ -3,6 +3,7 @@
# by the operator. Please use additional -e env.yaml.
parameter_defaults:
EnablePackageInstall: false
ServerDeletionPolicy: delete
UpgradeLevelNovaCompute: ''
UpgradeInitCommonCommand: ''
UpgradeInitCommand: ''

View File

@ -9,6 +9,7 @@ resource_registry:
parameter_defaults:
EnablePackageInstall: true
ServerDeletionPolicy: retain
UpgradeLevelNovaCompute: auto
UpgradeInitCommonCommand: |
#!/bin/bash