Explain duplicate checks includes tags and when (#68183)
##### SUMMARY Per #67913, when comparing dependencies, Ansible takes into account parameters, tags and the when clause in determining whether a role is a duplicate or not. ##### ISSUE TYPE - Docs Pull Request +label: docsite_pr
This commit is contained in:
parent
1425e3597b
commit
3e4377300b
1 changed files with 1 additions and 1 deletions
|
@ -324,7 +324,7 @@ Ansible always executes role dependencies before the role that includes them. An
|
|||
Running role dependencies multiple times in one playbook
|
||||
--------------------------------------------------------
|
||||
|
||||
Ansible treats duplicate role dependencies like duplicate roles listed under ``roles:``: Ansible only executes role dependencies once, even if defined multiple times, unless the parameters defined on the role are different for each definition. If two roles in a playbook both list a third role as a dependency, Ansible only runs that role dependency once, unless you pass different parameters or use ``allow_duplicates: true`` in the dependent (third) role. See :ref:`Galaxy role dependencies <galaxy_dependencies>` for more details.
|
||||
Ansible treats duplicate role dependencies like duplicate roles listed under ``roles:``: Ansible only executes role dependencies once, even if defined multiple times, unless the parameters, tags, or when clause defined on the role are different for each definition. If two roles in a playbook both list a third role as a dependency, Ansible only runs that role dependency once, unless you pass different parameters, tags, when clause, or use ``allow_duplicates: true`` in the dependent (third) role. See :ref:`Galaxy role dependencies <galaxy_dependencies>` for more details.
|
||||
|
||||
For example, a role named ``car`` depends on a role named ``wheel`` as follows:
|
||||
|
||||
|
|
Loading…
Reference in a new issue