mirror of
https://github.com/freeipa/ansible-freeipa.git
synced 2026-07-31 11:54:47 +00:00
ipaconfig: Change ipalib.errors to module utils ipalib_errors.
Instead o importing ipalib.errors, modules must use ansible_freeipa_module.ipalib_errors.
This commit is contained in:
@@ -254,8 +254,7 @@ config:
|
|||||||
from ansible.module_utils.basic import AnsibleModule
|
from ansible.module_utils.basic import AnsibleModule
|
||||||
from ansible.module_utils.ansible_freeipa_module import temp_kinit, \
|
from ansible.module_utils.ansible_freeipa_module import temp_kinit, \
|
||||||
temp_kdestroy, valid_creds, api_connect, api_command_no_name, \
|
temp_kdestroy, valid_creds, api_connect, api_command_no_name, \
|
||||||
compare_args_ipa, module_params_get
|
compare_args_ipa, module_params_get, ipalib_errors
|
||||||
import ipalib.errors
|
|
||||||
|
|
||||||
|
|
||||||
def config_show(module):
|
def config_show(module):
|
||||||
@@ -464,7 +463,7 @@ def main():
|
|||||||
exit_args[k] = (v[0] == "TRUE")
|
exit_args[k] = (v[0] == "TRUE")
|
||||||
else:
|
else:
|
||||||
exit_args[k] = v
|
exit_args[k] = v
|
||||||
except ipalib.errors.EmptyModlist:
|
except ipalib_errors.EmptyModlist:
|
||||||
changed = False
|
changed = False
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
ansible_module.fail_json(msg="%s %s" % (params, str(e)))
|
ansible_module.fail_json(msg="%s %s" % (params, str(e)))
|
||||||
|
|||||||
Reference in New Issue
Block a user