implemented 'inventory_file' variable. Closes GH-3789.

This commit is contained in:
René Moser 2013-08-10 12:59:17 +02:00
commit e8272e365d
No known key found for this signature in database
GPG key ID: 1D7BBF44E53168C7
3 changed files with 13 additions and 0 deletions

View file

@ -397,6 +397,12 @@ class Inventory(object):
return cwd
return dname
def src(self):
""" if inventory came from a file, what's the directory and file name? """
if not self.is_file():
return None
return self.host_list
def playbook_basedir(self):
""" returns the directory of the current playbook """
return self._playbook_basedir