August 2017
Intermediate to advanced
332 pages
9h 16m
English
A playbook is composed of one or many plays. Each play contains a host group name, tasks to perform, and configuration details (for example, remote username or access rights). An example playbook might look like this:
---- hosts: web1 become: yes become_method: sudo tasks: - name: ensure apache is at the latest version apt: name=apache2 state=latest - name: ensure apache is running service: name=apache2 state=started enabled=yes
This configuration contains one play which:
Read now
Unlock full access