Add LB starting logic in LB restoring logic and fix DecortController.lb_state method VALID_TARGET_STATES list
This commit is contained in:
@@ -135,8 +135,7 @@ class decort_lb(DecortController):
|
||||
self.lb_restore(lb_id=self.lb_id)
|
||||
_, self.lb_facts = self._lb_get_by_id(lb_id=self.lb_id)
|
||||
self.lb_state(self.lb_facts, 'enabled')
|
||||
self.lb_facts['status'] = "ENABLED"
|
||||
self.lb_facts['techStatus'] = "STARTED"
|
||||
_, self.lb_facts = self._lb_get_by_id(lb_id=self.lb_id)
|
||||
|
||||
self.lb_update(
|
||||
self.lb_facts['primaryNode'],
|
||||
@@ -322,7 +321,7 @@ def main():
|
||||
decon.action(amodule.params['state'])
|
||||
elif decon.lb_facts['status'] == "DELETED":
|
||||
if amodule.params['state'] in ['present', 'enabled']:
|
||||
decon.action(restore=True)
|
||||
decon.action(d_state='started', restore=True)
|
||||
elif (amodule.params['state'] == 'absent' and
|
||||
amodule.params['permanently']):
|
||||
decon.delete()
|
||||
|
||||
Reference in New Issue
Block a user