changed syntax as insert isn't required

This commit is contained in:
gamuniz 2020-02-26 14:28:22 +00:00
parent 58c06d5aea
commit 350046d495

View File

@ -106,7 +106,7 @@ def could_be_inventory(project_path, dir_path, filename):
def read_ansible_config(project_path, variables_of_interest):
fnames = ['/etc/ansible/ansible.cfg']
if project_path:
fnames.insert(1, os.path.join(project_path, 'ansible.cfg'))
fnames.append(os.path.join(project_path, 'ansible.cfg'))
values = {}
try:
parser = ConfigParser()