mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-26 14:41:23 -07:00
* Add lookup_dig tests
* Fix boolean evaluation
* Add changelog fragment
* Apply review changes
* Add license
(cherry picked from commit 3c2d7eb193
)
Co-authored-by: Michal Hybner <76526074+mu1f407@users.noreply.github.com>
This commit is contained in:
parent
43e599abb1
commit
2e11c2dfa4
5 changed files with 55 additions and 2 deletions
|
@ -175,6 +175,7 @@ RETURN = """
|
|||
from ansible.errors import AnsibleError
|
||||
from ansible.plugins.lookup import LookupBase
|
||||
from ansible.module_utils.common.text.converters import to_native
|
||||
from ansible.module_utils.parsing.convert_bool import boolean
|
||||
from ansible.utils.display import Display
|
||||
import socket
|
||||
|
||||
|
@ -327,9 +328,9 @@ class LookupModule(LookupBase):
|
|||
except Exception as e:
|
||||
raise AnsibleError("dns lookup illegal CLASS: %s" % to_native(e))
|
||||
elif opt == 'retry_servfail':
|
||||
myres.retry_servfail = bool(arg)
|
||||
myres.retry_servfail = boolean(arg)
|
||||
elif opt == 'fail_on_error':
|
||||
fail_on_error = bool(arg)
|
||||
fail_on_error = boolean(arg)
|
||||
|
||||
continue
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue