No inventory was parsed, only implicit localhost is available

3.67K viewsAnsibleansible ansible-playbook playbook

No inventory was parsed, only implicit localhost is available

I am getting these warning messages while executing the ansible-playbook

[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'

Is there a way to remove these warnings?

Share:
vito Edited question June 5, 2021
0

To suppress these warning messages, you can edit the inventory file and write localhost in it. Execute the below command to edit the inventory file,

sudo nano /etc/ansible/hosts

Write localhost at the very bottom of the file. Save and exit. Run the playbook again.

Share:
hiberstackers Answered question February 24, 2021
0
You are viewing 1 out of 1 answers, click here to view all answers.