ansible/docs/docsite/rst
James Cammarata a2599cab79 Fix variable precedence of INI/script vars to be in-line with docs.
This commit also adds a new test script (ansible-var-precedence-check.py in code-smell/)
to provide us with another line of defense against precedence bugs going forward.

The precedence docs state that the INI vars have a lower precedence than group/host
vars files for inventory and playbooks, however that has not been the case since 2.0
was released. This change fixes that in one way, though not exactly as the docs say.
The rules are:

1) INI/script < inventory dir < playbook dir
2) "all" group vars < other group_vars < host_vars

So the new order will be (from the test script mentioned above):

8. pb_host_vars_file - var in playbook/host_vars/host
9. ini_host_vars_file - var in inventory/host_vars/host
10. ini_host - host var inside the ini
11. pb_group_vars_file_child - var in playbook/group_vars/child
12. ini_group_vars_file_child - var in inventory/group_vars/child
13. pb_group_vars_file_parent - var in playbook/group_vars/parent
14. ini_group_vars_file_parent - var in inventory/group_vars/parent
15. pb_group_vars_file_all - var in playbook/group_vars/all
16. ini_group_vars_file_all - var in inventory/group_vars/all
17. ini_child - child group var inside the ini
18. ini_parent - parent group var inside the ini
19. ini_all - all group var inside the ini

Fixes #21845
2017-03-02 17:07:00 -06:00
..
dev_guide Make the metadata docs agree with what's currently implemented 2017-02-27 09:27:00 -05:00
modules
roadmap initial commit of win_domain module (#22179) 2017-03-01 17:49:15 -08:00
become.rst become options dont qualify as new anymore 2017-02-08 11:51:15 -05:00
committer_guidelines.rst
common_return_values.rst Don't mix deprecations messages with warnings messages (#21337) 2017-02-13 23:49:39 -05:00
community.rst Make pull-request sentence less ambiguous (#21802) 2017-02-22 17:52:41 -08:00
conf.py PEP 8 indent cleanup. (#20800) 2017-01-29 07:28:53 +00:00
faq.rst Fix Passlib example in FAQ (#21997) 2017-02-27 10:14:02 -05:00
galaxy.rst Add role skeleton support (#17079) 2017-03-01 20:23:18 -05:00
glossary.rst
guide_aws.rst
guide_azure.rst
guide_cloudstack.rst Fix all RST errors for docs/docsite/rst (#20005) 2017-01-07 11:38:52 -08:00
guide_docker.rst
guide_gce.rst
guide_rax.rst
guide_rolling_upgrade.rst Use HTTPS instead of legacy HTTP for ansible.com (#16870) 2017-02-15 16:09:33 -08:00
guide_vagrant.rst
guides.rst
index.rst
intro.rst
intro_adhoc.rst
intro_bsd.rst Fix all RST errors for docs/docsite/rst (#20005) 2017-01-07 11:38:52 -08:00
intro_configuration.rst Fix docs re inventory_ignore_extensions config (#21132) 2017-02-10 00:32:22 -08:00
intro_dynamic_inventory.rst Fix docs re inventory_ignore_extensions config (#21132) 2017-02-10 00:32:22 -08:00
intro_getting_started.rst
intro_installation.rst Move to using a requirements.txt to install the python packages. (#21430) 2017-02-15 06:58:09 -08:00
intro_inventory.rst Update docker example on Inventory page (#20209) 2017-01-12 18:57:27 -08:00
intro_networking.rst Delete link to test-network-modules (#21347) 2017-02-13 18:25:15 +00:00
intro_patterns.rst Fix all RST errors for docs/docsite/rst (#20005) 2017-01-07 11:38:52 -08:00
intro_windows.rst Clarify what modules are available for Windows (#21888) 2017-03-01 22:09:10 -08:00
modules.rst Doc module meta (#20093) 2017-01-10 12:58:22 -08:00
modules_intro.rst Fix all RST errors for docs/docsite/rst (#20005) 2017-01-07 11:38:52 -08:00
modules_support.rst Updated wording around support for different modules 2017-02-13 09:40:22 -05:00
playbooks.rst Doc fixes (#20353) 2017-01-17 18:55:03 -08:00
playbooks_acceleration.rst
playbooks_advanced_syntax.rst Fix all RST errors for docs/docsite/rst (#20005) 2017-01-07 11:38:52 -08:00
playbooks_async.rst
playbooks_best_practices.rst Update playbooks_best_practices.rst (#21288) 2017-02-12 00:01:43 -08:00
playbooks_blocks.rst added clarification on directives/blocks 2017-01-16 11:01:55 -05:00
playbooks_checkmode.rst
playbooks_conditionals.rst service state typo 2017-02-14 10:47:37 -05:00
playbooks_debugger.rst Fix all RST errors for docs/docsite/rst (#20005) 2017-01-07 11:38:52 -08:00
playbooks_delegation.rst
playbooks_environment.rst
playbooks_error_handling.rst fixed phrasing on 0 being non error 2017-01-13 20:55:45 -05:00
playbooks_filters.rst more set/list stuff 2017-02-28 10:44:20 -05:00
playbooks_filters_ipaddr.rst Doc fixes (#20353) 2017-01-17 18:55:03 -08:00
playbooks_intro.rst Fix all RST errors for docs/docsite/rst (#20005) 2017-01-07 11:38:52 -08:00
playbooks_lookups.rst Make password lookup treat /dev/null as a special case 2017-02-15 12:15:09 -08:00
playbooks_loops.rst docks: add missing colon character 2017-03-01 08:26:30 -08:00
playbooks_prompts.rst Update references to Passlib as homepage/docsite moved (#20082) 2017-01-10 13:17:32 +00:00
playbooks_roles.rst Use HTTPS instead of legacy HTTP for ansible.com (#16870) 2017-02-15 16:09:33 -08:00
playbooks_special_topics.rst
playbooks_startnstep.rst
playbooks_strategies.rst
playbooks_tags.rst clarified tag usage 2017-01-25 10:52:07 -05:00
playbooks_templating.rst corrected which app adds plugins 2017-01-18 14:14:28 -05:00
playbooks_tests.rst Doc fixes (#20353) 2017-01-17 18:55:03 -08:00
playbooks_variables.rst Fix variable precedence of INI/script vars to be in-line with docs. 2017-03-02 17:07:00 -06:00
playbooks_vault.rst added docs for vault and made trigger shorter: !vault (#20985) 2017-02-03 15:28:50 -05:00
porting_guide_2.0.rst Some more code-block fixes 2017-01-07 11:47:35 -08:00
python_3_support.rst
quickstart.rst
test_strategies.rst
tower.rst Use HTTPS instead of legacy HTTP for ansible.com (#16870) 2017-02-15 16:09:33 -08:00
YAMLSyntax.rst