Removing PLUMgrid restart on LCM Key post
This commit is contained in:
parent
1d5c433f9a
commit
d6be75bbae
@ -70,6 +70,9 @@ def config_changed():
|
||||
This hook is run when a config parameter is changed.
|
||||
It also runs on node reboot.
|
||||
'''
|
||||
if add_lcm_key():
|
||||
log("PLUMgrid LCM Key added")
|
||||
return 1
|
||||
stop_pg()
|
||||
configure_sources(update=True)
|
||||
pkgs = determine_packages()
|
||||
|
@ -212,3 +212,4 @@ def add_lcm_key():
|
||||
fa.write(key)
|
||||
fa.write('\n')
|
||||
fa.close()
|
||||
return 1
|
||||
|
@ -71,6 +71,7 @@ class PGGwHooksTests(CharmTestCase):
|
||||
|
||||
def test_config_changed_hook(self):
|
||||
_pkgs = ['plumgrid-lxc', 'iovisor-dkms']
|
||||
self.add_lcm_key.return_value = 0
|
||||
self.determine_packages.return_value = [_pkgs]
|
||||
self._call_hook('config-changed')
|
||||
self.stop_pg.assert_called_with()
|
||||
@ -82,7 +83,6 @@ class PGGwHooksTests(CharmTestCase):
|
||||
self.load_iovisor.assert_called_with()
|
||||
self.ensure_mtu.assert_called_with()
|
||||
self.ensure_files.assert_called_with()
|
||||
self.add_lcm_key.assert_called_with()
|
||||
self.CONFIGS.write_all.assert_called_with()
|
||||
self.restart_pg.assert_called_with()
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user