O'Reilly logo

Learning Ansible by Ramesh Raithatha, Madhurranjan Mohaan

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Working with modules

Now that we've seen how playbooks, variables, and inventories come together, let's look at modules in greater detail. Ansible provides more than 200 modules under top-level modules, such as System, Network, Database, and Files, that you can readily use and deal with in your infrastructure. The module index page has more details regarding the categories of the module. We'll explore modules that are commonly used and look at more advanced modules in later chapters.

Command modules

We start with four modules that are pretty similar to each other. They are used to execute tasks on remote machines. We need to take care of idempotency for most tasks that involve any of the above modules using conditional clauses that we will see in ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required