Commit e1f5b801 by jay

fixed bug causing symlinks to fail in the host_vars, group_vars etc directories

parent 78ec7c73
...@@ -73,7 +73,7 @@ def _load_vars_from_path(path, results): ...@@ -73,7 +73,7 @@ def _load_vars_from_path(path, results):
# symbolic link # symbolic link
if stat.S_ISLNK(pathstat.st_mode): if stat.S_ISLNK(pathstat.st_mode):
try: try:
target = os.readlink(path) target = os.path.realpath(path)
except os.error, err2: except os.error, err2:
raise errors.AnsibleError("The symbolic link at %s " raise errors.AnsibleError("The symbolic link at %s "
"is not readable: %s. Please check its permissions." "is not readable: %s. Please check its permissions."
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment