1.

What are handlers?

Answer»

Handlers are LIKE SPECIAL tasks which only run if the Task contains a “notify” directive. 

tasks: - NAME: install nginx apt: pkg=nginx state=installed update_cache=true notify: - start nginx handlers: - name: start nginx service: name=nginx state=started

In the above example after INSTALLING NGINX we are starting the server USING a `start nginx` handler.



Discussion

No Comment Found