From charlesreid1

Revision as of 08:21, 8 December 2018 by Admin (talk | contribs) (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...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

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 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