Skip to content
Snippets Groups Projects
Commit 3390d674 authored by Thomas Woerner's avatar Thomas Woerner
Browse files

ansible_freeipa_module: New function api_check_param

api_check_param can be used to verify if params are available for a command
in the used FreeIPA version. The function has been added as api is normally
not imported into modules.
parent 57188c89
No related branches found
No related tags found
No related merge requests found
...@@ -127,6 +127,13 @@ def api_command(module, command, name, args): ...@@ -127,6 +127,13 @@ def api_command(module, command, name, args):
return api.Command[command](name, **args) return api.Command[command](name, **args)
def api_check_param(command, name):
"""
Return if param exists in command param list
"""
return name in api.Command[command].params
def execute_api_command(module, principal, password, command, name, args): def execute_api_command(module, principal, password, command, name, args):
""" """
Get KRB ticket if not already there, initialize api, connect, Get KRB ticket if not already there, initialize api, connect,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment