From 081730851c1e81063ae7433c4871bbffd8d646bd Mon Sep 17 00:00:00 2001 From: Senthil Kumar Ganesan Date: Mon, 19 Sep 2016 14:41:30 -0700 Subject: [PATCH] Fix to handle the prompt on saving startup config --- lib/ansible/module_utils/dellos9.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/ansible/module_utils/dellos9.py b/lib/ansible/module_utils/dellos9.py index 536dd2a92a1..7e4b0a482aa 100755 --- a/lib/ansible/module_utils/dellos9.py +++ b/lib/ansible/module_utils/dellos9.py @@ -123,7 +123,10 @@ class Cli(CliBase): def save_config(self): - self.execute(['copy running-config startup-config']) + cmdlist = list() + cmd = 'copy running-config startup-config' + cmdlist.append(Command(cmd, prompt=self.WARNING_PROMPTS_RE, response='yes')) + self.execute(cmdlist) Cli = register_transport('cli', default=True)(Cli)