July 2017
Intermediate to advanced
266 pages
6h 36m
English
Ansible plays are named after sports plays. In YAML, plays are represented via one or more tasks sections within a playbook. The plays section (or sections) of an Ansible playbook represents the heart of the Ansible automation engine. In Ansible, each task has a name (a user-friendly description of the action to be executed) and a set of parameters that define how the system should execute, report on, or handle the aftermath of the execution. Let's take a look at a couple of ways in which we can implement Ansible plays within a given playbook.
The example provided next provides us with a glimpse into an Ansible playbook with a single play:
tasks: - name: Can we use Ansible to Install Apache2 web server apt: pkg=apache2 state=installed ...
Read now
Unlock full access