Hi @KodeKloud team
I have one query regarding ansible-playbook command, I kept my inventory file and YAML playbook in same directory , when i run
ansible-playbook playbook.yml --> I am getting message “No matching hosts” .
But when i explicitly mention a dynamic inventory command like
ansible-playbook -i inventory playbook.yml --> then it successfully executes the desired action, now my query is :
what is the difference between >> ansible-playbook playbook.yml & >> ansible-playbook -i inventory playbook.yml while i have my inventory file and playbook.yml file under same directory ?