Skip to content

Commit

Permalink
Add missing parameters in get_config vyos (#50855)
Browse files Browse the repository at this point in the history
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
(cherry picked from commit fc0f20a)
  • Loading branch information
trishnaguha authored and abadger committed Apr 4, 2019
1 parent cb5f043 commit 5d73a98
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions lib/ansible/module_utils/network/vyos/vyos.py
Expand Up @@ -90,15 +90,16 @@ def get_capabilities(module):
return module._vyos_capabilities


def get_config(module):
def get_config(module, flags=None, format=None):
flags = [] if flags is None else flags
global _DEVICE_CONFIGS

if _DEVICE_CONFIGS != {}:
return _DEVICE_CONFIGS
else:
connection = get_connection(module)
try:
out = connection.get_config()
out = connection.get_config(flags=flags, format=format)
except ConnectionError as exc:
module.fail_json(msg=to_text(exc, errors='surrogate_then_replace'))
cfg = to_text(out, errors='surrogate_then_replace').strip()
Expand Down

0 comments on commit 5d73a98

Please sign in to comment.