The Ansible files can be made reusable in following ways-

  • Include
  • Role
  • Import

In order to break or create the number of smaller files of any huge playbook imports and includes are used. Rolls are used to organize and manage multiple tasks following a package including plugin, variables, handlers and other modules. By using Ansible galaxy they can also be uploaded and shared directly.

BY Best Interview Question ON 05 Oct 2019