Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
+1 vote
2 views
in DevOps and Agile by (29.3k points)

When i try to run site.yaml(playbook for role), i am getting the following error:

Here, it is showing me this error when i run install.yaml(playbook for installing the software inside a role) It gives me no error.

Any insights regarding this will be helpful.

1 Answer

0 votes
by (50.2k points)

Reason: This occurs due to syntax issues, and if your node machine doesn't consist of proper permissions to install the software.

TL/DR: You need to check the /etc/ansible/hosts file and add the node-user that you want to run this playbook.

Solution: Due to the recent updates with ansible, we cannot grant sudo permissions directly from the playbook. For this you need to mention the user inside /etc/ansible/hosts/ as shown below:

Then remove all sudo permissions from your playbook. Which will help you to run the playbook, and modify your site.yaml as shown below:

 For more information check out this ansible tutorial.

31k questions

32.8k answers

501 comments

693 users

Browse Categories

...