My playbook includes one single play. Every tasks in play imports - 
'import_role:' - one single role each. Every of imported roles is stored to 
own dedicated repository. This playbook is usually run from wrapper 
playbook which includes - 'include_playbook:' - the former one. Wrapper 
playbook imports more playbooks to conduct complete whole mission.
Tasks in my playbook should be carried out only under one condition - which 
is under implementation.
So I started to look for location in whole structure where is the optimal 
place for 'when:'. Conditionals  are not supported at import_playbook's 
level so I started to have a look
into my playbook and placed 'when:' in every task which imports a role. In 
end-effect the condition is checked in my playbook.
Next step is to find optimal location for variable default value 
enforcement. Ansible documentation mentions: "As described in Roles 
<https://docs.ansible.com/ansible/latest/user_guide/playbooks_reuse_roles.html#playbooks-reuse-roles>,
 
variables can also be included in the playbook via include files, which may 
or may not be part of an Ansible Role."  Actually documentation chapter 
"Roles" describes outsourcing variable settlement to intended files in role 
tree structure. My repository with playbooks tree inside is free however 
from tree of directories/files typical for role.
How to apply recommendations made for roles directory tree onto repository 
with playbooks which is free of role directories tree?

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/089ef011-803c-40ed-9af4-67c592225458%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to