My inventories are defined in a modified default Ansible 'Hosts' file. When I specify the -i {inventory} {.yml} I receive an error.
ansible 2.8.0 config file = /etc/ansible/ansible.cfg
configured module search path = [u'/home/kjames/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']
ansible python module location = /usr/lib/python2.7/site-packages/ansible
executable location = /usr/bin/ansible
python version = 2.7.5 (default, Apr 9 2019, 14:30:50) [GCC 4.8.5 20150623 (Red Hat 4.8.5-36)]
I've told Ansible where the hosts file is in ansible.cfg
, e.g.
[defaults]
inventory=buildservers-test
Actual Results:
$ ansible-playbook -i buildservers-test deploy-mxdk-tar.yaml -k --limit wbls12ex6401
[WARNING]: Unable to parse /home/kjames/ds9/playbooks/buildservers-test as an inventory source
[WARNING]: No inventory was parsed, only implicit localhost is available
[WARNING]: provided hosts list is empty, only localhost is available. Note that the implicit localhost does not match 'all' [WARNING]: Could not match supplied host pattern, ignoring: wbls12ex6401
[WARNING]: Could not match supplied host pattern, ignoring: testservers
PLAY [testservers] ***********************************************************************
skipping: no hosts matched
PLAY RECAP ****************************************************************************