⚙️ Ansible
Configuration File

Updated at 2017-03-22 01:46

Ansible will try to find a configuration file from:

  • ANSIBLE_CONFIG environment variable
  • ansible.cfg (in the current directory)
  • .ansible.cfg (in the home directory)
  • /etc/ansible/ansible.cfg

Example ansible.cfg with a comment:

inventory = ./  ; This points to the file that lists your hosts
host_key_checking = False

And now you don't have to specify the inventory file -i.

ansible all -m ping

More details in Ansible config documentation.