sends save command in text mode otherwise it fails (#21812)

Sending the save command over nxapi requires text mode otherwise nxapi
will reject the command.  This commit ensures that the command is always
sent in text mode

fixes #18971
pull/21810/head
Peter Sprygada 8 years ago committed by GitHub
parent 0e7ebf6391
commit 730bd682c6

@ -332,7 +332,8 @@ def main():
if module.params['save']:
if not module.check_mode:
run_commands(module, ['copy running-config startup-config'])
cmd = {'command': 'copy running-config startup-config', 'output': 'text'}
run_commands(module, [cmd])
result['changed'] = True
module.exit_json(**result)

Loading…
Cancel
Save