Commit 51a180b1 by ftao

fix inventory.basedir is not absolute path when hostfile is startswith "./"

parent 4d1f4479
......@@ -392,7 +392,7 @@ class Inventory(object):
if not self.is_file():
return None
dname = os.path.dirname(self.host_list)
if dname is None or dname == '':
if dname is None or dname == '' or dname == '.':
cwd = os.getcwd()
return cwd
return dname
......
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