added doc notes about vars plugins in precedence

pull/32462/head
Brian Coca 7 years ago committed by Toshio Kuratomi
parent c239749052
commit 52c97a1cf4

@ -858,14 +858,17 @@ In 2.x, we have made the order of precedence more specific (with the last listed
* role defaults [1]_ * role defaults [1]_
* inventory file or script group vars [2]_ * inventory file or script group vars [2]_
* inventory group_vars/all * inventory group_vars/all [3]_
* playbook group_vars/all * playbook group_vars/all [3]_
* inventory group_vars/* * inventory group_vars/* [3]_
* playbook group_vars/* * playbook group_vars/* [3]_
* inventory file or script host vars [2]_ * inventory file or script host vars [2]_
* inventory host_vars/* * inventory host_vars/*
* playbook host_vars/* * playbook host_vars/*
* host facts / cached set_facts [3]_ * host facts / cached set_facts [4]_
* inventory host_vars/* [3]_
* playbook host_vars/* [3]_
* host facts
* play vars * play vars
* play vars_prompt * play vars_prompt
* play vars_files * play vars_files
@ -884,7 +887,8 @@ Basically, anything that goes into "role defaults" (the defaults folder inside t
.. [1] Tasks in each role will see their own role's defaults. Tasks defined outside of a role will see the last role's defaults. .. [1] Tasks in each role will see their own role's defaults. Tasks defined outside of a role will see the last role's defaults.
.. [2] Variables defined in inventory file or provided by dynamic inventory. .. [2] Variables defined in inventory file or provided by dynamic inventory.
.. [3] When created with set_facts's cacheable option, variables will have the high precedence in the play, .. [3] Includes vars added by 'vars plugins' as well as host_vars and group_vars which are added by the default vars plugin shipped with Ansible.
.. [4] When created with set_facts's cacheable option, variables will have the high precedence in the play,
but will be the same as a host facts precedence when they come from the cache. but will be the same as a host facts precedence when they come from the cache.
.. note:: Within any section, redefining a var will overwrite the previous instance. .. note:: Within any section, redefining a var will overwrite the previous instance.

Loading…
Cancel
Save