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

Chapter 5. Working with Custom Modules

 

"Customize your thoughts in order to personalize your behavior."

 
 -- Joseph Mercado, author of "The Undiscovered You"

The preceding quote is in the context of a human being's thoughts and behavior, but if you start to think about it and apply a similar philosophy to the technology and tools that you use, you'll feel that it fits in quite well.

This chapter will focus on how to write and test custom modules. We've already discussed how modules work and how to use them within your tasks. Well, just for a quick recap, a module in Ansible is a piece of code, which is transferred and executed on your remote host every time you run an Ansible task (it can also run locally if you've used local_action).

From our ...

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