adhoc ansible facts filter code example
Example: ansible select inventory file to adhoc command
# Use flag -i and the path to the inventory.
ansible all -i=/etc/ansible/[your_inventory] -m ping
# Use flag -i and the path to the inventory.
ansible all -i=/etc/ansible/[your_inventory] -m ping