diff --git a/lookup_plugins/re2oapi.py b/lookup_plugins/re2oapi.py index 3e047916..b4a87fc7 100644 --- a/lookup_plugins/re2oapi.py +++ b/lookup_plugins/re2oapi.py @@ -21,10 +21,20 @@ sys.path.append('./lookup_plugins/') from re2oapi import Re2oAPIClient - class LookupModule(LookupBase): """ - If terms = dnszones then this module queries the re2o api and returns the list of all dns zones + If terms = dnszones then this module queries the re2o api and returns the list of all dns zones. + + + Usage: + + The following play will use the debug module to output all the zone names managed by crans. + + - hosts: sputnik.adm.crans.org + vars: + dnszones: "{{ lookup('re2oapi', 'dnszones', api_hostname='intranet.crans.org') }}" + tasks: + - debug: var=dnszones """