What is dynamic inventory in Ansible

0 votes

Hi Guys,

I am new to Ansible. I don't know too much about inventory file. Can anyone tell me what is dynamic inventory?

Sep 20, 2020 in Ansible by akhtar
• 38,230 points
2,642 views

1 answer to this question.

0 votes

Hi@akhtar,

In a configuration especially a cloud setup such as AWS where the inventory file keeps constantly changing as you add or decommission servers, keeping tabs on the hosts defined in the inventory file becomes a real challenge. It becomes inconvenient going back to the host file and updating the list of hosts with their IP addresses.

And this is where a dynamic inventory comes to play. A dynamic inventory is a script written in Python, PHP, or any other programming language. It comes in handy in cloud environments such as AWS where IP addresses change once a virtual server is stopped and started again.

Ansible already has developed inventory scripts for public cloud platforms such as Google Compute Engine, Amazon EC2 instance, OpenStack, RackSpace, cobbler, among others.

answered Sep 20, 2020 by MD
• 95,440 points

Related Questions In Ansible

0 votes
1 answer

What is the difference between the host file and an inventory file in ansible?

Actually both are same. hosts file is ...READ MORE

answered Feb 12, 2019 in Ansible by Amith
• 140 points
7,236 views
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer

what is the difference between tags and delegate_to in ansible?

Hey @Rajendra, If you wish to perform ...READ MORE

answered Sep 24, 2019 in Ansible by Kalgi
• 52,360 points
1,648 views
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
3,503 views
+2 votes
1 answer
0 votes
1 answer

What is a template in Ansible?

Hi@akhtar, Managing configurations of multiple servers and environments are ...READ MORE

answered Aug 2, 2020 in Ansible by MD
• 95,440 points
382 views
0 votes
1 answer

What is the ask_pass module in Ansible?

Hi@akhtar, Ask_pass is the control module in an ...READ MORE

answered Aug 11, 2020 in Ansible by MD
• 95,440 points
2,579 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP