Last active
February 14, 2017 08:54
-
-
Save parberge/83c6fa21625b4acbdb797bc40a8a68be to your computer and use it in GitHub Desktop.
ansible lookup(dig)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
task: | |
- name: "Check DNS records for host" | |
set_fact: | |
dns_a_record: "{{ lookup('dig', ansible_fqdn) }}" | |
dns_ptr_record: "{{ lookup('dig', ansible_default_ipv4['address'] + '/PTR') }}" | |
output: | |
TASK [core : Check DNS records for host] *************************************** | |
fatal: [xxxx]: FAILED! => {"failed": true, "msg": "dns.resolver unhandled exception"} | |
to retry, use: --limit @/tmp/ansible/retry-files/baseline.retry | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
$ ansible --version
ansible 2.2.0.0