Ansible/Tasks: Difference between revisions
From charlesreid1
(Created page with "{{Main|Ansible}} This page covers more information about Ansible tasks. =Basics= Tasks can be organized for playbooks in various ways. The easiest and simplest way is to p...") |
No edit summary |
||
| Line 1: | Line 1: | ||
{{Main|Ansible}} | {{Main|Ansible}} | ||
This page covers | This page covers Ansible tasks in greater detail. | ||
=Basics= | =Basics= | ||
Latest revision as of 08:21, 8 December 2018
Main article: Ansible
This page covers Ansible tasks in greater detail.
Basics
Tasks can be organized for playbooks in various ways.
The easiest and simplest way is to place all tasks (along with all other playbook information) into a single YAML file in the top level playbooks directory.
playbooks/
hosts
site.yml
An alternative way that gives finer grained control is to include a tasks directory in the top level playbooks directory, and either use a single task file that contains all tasks, or split tasks into different YAML files:
playbooks/
hosts
site.yml
tasks/
main.yml
foo.yml
bar.yml
Flags