git://git.halfball.org
/
ansiblebook.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e9f092d
)
Use explicit import
author
Lorin Hochstein
<lhochstein@netflix.com>
Wed, 11 Jan 2017 07:04:44 +0000
(23:04 -0800)
committer
Lorin Hochstein
<lhochstein@netflix.com>
Wed, 11 Jan 2017 07:04:44 +0000
(23:04 -0800)
ch10/playbooks/library/can_reach
patch
|
blob
|
history
diff --git
a/ch10/playbooks/library/can_reach
b/ch10/playbooks/library/can_reach
index
3c78849
..
1b1ff9f
100644
(file)
--- a/
ch10/playbooks/library/can_reach
+++ b/
ch10/playbooks/library/can_reach
@@
-1,4
+1,5
@@
#!/usr/bin/python
+from ansible.module_utils.basic import AnsibleModule
def can_reach(module, host, port, timeout):
nc_path = module.get_bin_path('nc', required=True)
@@
-33,5
+34,4
@@
def main():
msg = "Could not reach %s:%s" % (host, port)
module.fail_json(msg=msg)
-from ansible.module_utils.basic import *
main()