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

ansible_freeipa_module: New api_get_basedn, IPAAnsibleModule.ipa_get_basedn

These functions have been added to get the basedb from api.env for use
with DN for example.

api_get_basedn is returning api.env.basedn
IPAAnsibleModule.ipa_get_basedn is a wrapper for api_get_basedn
parent e7f902ca
Branches
Tags
Loading
...@@ -419,6 +419,9 @@ else: ...@@ -419,6 +419,9 @@ else:
def api_get_realm(): def api_get_realm():
return api.env.realm return api.env.realm
def api_get_basedn():
return api.env.basedn
def gen_add_del_lists(user_list, res_list): def gen_add_del_lists(user_list, res_list):
""" """
Generate the lists for the addition and removal of members. Generate the lists for the addition and removal of members.
...@@ -882,6 +885,11 @@ else: ...@@ -882,6 +885,11 @@ else:
"""Retrieve IPA API realm.""" """Retrieve IPA API realm."""
return api_get_realm() return api_get_realm()
@staticmethod
def ipa_get_basedn():
"""Retrieve IPA API basedn."""
return api_get_basedn()
@staticmethod @staticmethod
def ipa_command_exists(command): def ipa_command_exists(command):
""" """
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment