From ca7e2d283c63cc285ee656a72a30dc916d83141a Mon Sep 17 00:00:00 2001 From: egghead Date: Mon, 14 Oct 2013 23:41:16 +0000 Subject: [PATCH] Adding os realpath filter. This is particularly useful when wanting to get the absolute path of filepaths found by the 'fileglob' filter. This also lets you provide absolute paths to roles, which search for files in different areas unless absolutely pathed. --- lib/ansible/runner/filter_plugins/core.py | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/ansible/runner/filter_plugins/core.py b/lib/ansible/runner/filter_plugins/core.py index 55bde22abcf..28eed6c4458 100644 --- a/lib/ansible/runner/filter_plugins/core.py +++ b/lib/ansible/runner/filter_plugins/core.py @@ -120,6 +120,7 @@ class FilterModule(object): # path 'basename': os.path.basename, 'dirname': os.path.dirname, + 'realpath': os.path.realpath, # failure testing 'failed' : failed,