200-901 · Question #437
Which capability is used by Ansible to run a set of tasks when a property is changed?
The correct answer is A. handlers. Sometimes you want a task to run only when a change is made on a machine. For example, you may want to restart a service if a task updates the configuration of that service, but not if the configuration is unchanged. Ansible uses handlers to address this use case. Handlers are…
Question
Which capability is used by Ansible to run a set of tasks when a property is changed?
Options
- Ahandlers
- Bplaybooks
- Croles
- Dtasks
How the community answered
(44 responses)- A95% (42)
- B2% (1)
- D2% (1)
Explanation
Sometimes you want a task to run only when a change is made on a machine. For example, you may want to restart a service if a task updates the configuration of that service, but not if the configuration is unchanged. Ansible uses handlers to address this use case. Handlers are tasks that only run when notified.
Topics
Community Discussion
No community discussion yet for this question.