nxos_install_os install_state fix

(cherry picked from commit 7dc60c3f24)
pull/30451/head
Nathaniel Case 7 years ago committed by Toshio Kuratomi
parent 06a066fe1b
commit eeba998592

@ -189,7 +189,6 @@ def main():
warnings = list() warnings = list()
check_args(module, warnings) check_args(module, warnings)
install_state = module.params['install_state']
system_image_file = module.params['system_image_file'] system_image_file = module.params['system_image_file']
kickstart_image_file = module.params['kickstart_image_file'] kickstart_image_file = module.params['kickstart_image_file']
@ -203,6 +202,7 @@ def main():
kickstart_image_file): kickstart_image_file):
changed = True changed = True
install_state = current_boot_options
if not module.check_mode and changed is True: if not module.check_mode and changed is True:
set_boot_options(module, set_boot_options(module,
system_image_file, system_image_file,
@ -213,8 +213,6 @@ def main():
kickstart_image_file): kickstart_image_file):
module.fail_json(msg='Install not successful', module.fail_json(msg='Install not successful',
install_state=install_state) install_state=install_state)
else:
install_state = current_boot_options
module.exit_json(changed=changed, install_state=install_state, warnings=warnings) module.exit_json(changed=changed, install_state=install_state, warnings=warnings)

Loading…
Cancel
Save