set up changes for option ha-legacy-mode

This commit is contained in:
Hui Xiang 2015-01-09 16:00:15 +08:00
parent 8ff6293816
commit ce1b5a8bf0
2 changed files with 4 additions and 0 deletions

View File

@ -118,7 +118,10 @@ def config_changed():
else: else:
apt_purge('neutron-l3-agent') apt_purge('neutron-l3-agent')
# Setup legacy ha configurations
update_legacy_ha_files() update_legacy_ha_files()
for r_id in relation_ids('ha'):
ha_relation_joined()
@hooks.hook('upgrade-charm') @hooks.hook('upgrade-charm')

View File

@ -649,6 +649,7 @@ def update_legacy_ha_files(force=False):
if config('ha-legacy-mode'): if config('ha-legacy-mode'):
install_legacy_ha_files(force=force) install_legacy_ha_files(force=force)
else: else:
delete_legacy_resources()
remove_legacy_ha_files() remove_legacy_ha_files()