Merge "Upgrade: fix hieradata software version mismatch"

This commit is contained in:
Zuul 2021-01-25 18:36:04 +00:00 committed by Gerrit Code Review
commit 3303a8a0cb
1 changed files with 8 additions and 2 deletions

View File

@ -8758,8 +8758,14 @@ class ConductorManager(service.PeriodicService):
host.invprovision == constants.PROVISIONED or
(host.invprovision == constants.PROVISIONING and
host.personality == constants.CONTROLLER)):
self._puppet.update_host_config(host, config_uuid)
host_updated = True
if host.software_load == tsc.SW_VERSION:
# We will not generate the hieradata in runtime here if the
# software load of the host is different from the active
# controller. The Hieradata of a host during an upgrade/rollback
# will be saved by update_host_config_upgrade() to the
# directory of the host's software load.
self._puppet.update_host_config(host, config_uuid)
host_updated = True
else:
LOG.info(
"Cannot regenerate the configuration for %s, "