1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00
community.general/docsite/rst
Abhijit Menon-Sen 8cf1815867 Add an 'extract' filter
At its most basic, this is nothing more than an array or hash lookup,
but when used in conjunction with map, it is very useful. For example,
while constructing an "ssh-keyscan …" command to update known_hosts on
all hosts in a group, one can get a list of IP addresses with:

    groups['x']|map('extract', hostvars, 'ec2_ip_address')|list

This returns hostvars[a].ec2_ip_address, hostvars[b].ec2_ip_address, and
so on. You can even specify an array of keys for a recursive lookup, and
mix string and integer keys depending on what you're looking up:

    ['localhost']|map('extract', hostvars, ['vars','group_names',0])|first
        == hostvars['localhost']['vars']['group_names'][0]
            == 'ungrouped'

Includes documentation and tests.
2015-12-02 18:16:38 +05:30
..
modules
ansible_ssh_changes_note.rst removed repetition of note and replaced with an include directive 2015-10-12 11:41:09 -04:00
become.rst typo fix 2015-09-15 10:00:01 -04:00
common_return_values.rst
community.rst Merge pull request #12097 from mgedmin/patch-1 2015-09-20 05:45:06 -07:00
developing.rst
developing_api.rst
developing_inventory.rst
developing_modules.rst Fix missing word in developing_modules.rst 2015-11-25 18:29:17 +01:00
developing_plugins.rst Fix typo 2015-09-21 09:59:28 -05:00
developing_test_pr.rst
faq.rst removed repetition of note and replaced with an include directive 2015-10-12 11:41:09 -04:00
galaxy.rst removes editorial 2015-11-27 10:09:55 +01:00
glossary.rst reordering entries in glossary for alphabetical order 2015-10-14 11:37:27 -04:00
guide_aws.rst Fix up rst formatting 2015-11-03 17:29:02 -08:00
guide_cloudstack.rst docsite: cloudstack: fix missing quotes in example 2015-11-23 07:10:47 +01:00
guide_gce.rst
guide_rax.rst Fix up rst formatting 2015-11-03 17:29:02 -08:00
guide_rolling_upgrade.rst
guide_vagrant.rst Documentation: Update the Vagrant Guide 2015-11-20 21:50:41 +01:00
guides.rst doc: add cloudstack guide to the guides 2015-10-31 19:34:40 +01:00
index.rst
intro.rst draft bsd intro and bootstrapping 2015-08-12 22:18:29 -04:00
intro_adhoc.rst
intro_bsd.rst Update intro_bsd.rst 2015-11-09 12:34:28 +13:00
intro_configuration.rst Update docs and example config for requiretty + pipelining change 2015-12-01 10:24:15 -08:00
intro_dynamic_inventory.rst Update ec2 inventory documentation to refer to AWS_PROFILE 2015-09-28 21:35:46 +05:30
intro_getting_started.rst Update doc to use 'become' instead of 'sudo' 2015-09-08 15:42:56 +05:30
intro_installation.rst Removed erroneous apostrophe in installation documentation 2015-11-15 00:04:11 +00:00
intro_inventory.rst added "include" for ansible_ssh_ change note to another section of intro_inventory.rst for clarity 2015-10-13 13:59:44 -04:00
intro_patterns.rst Corrected group separator 2015-11-30 21:44:18 -06:00
intro_windows.rst Recommend using pywinrm >= 0.1.1 from PyPI instead of GitHub version. 2015-11-18 17:49:21 -05:00
modules.rst
modules_core.rst Fix typo in modules_core.rst 2015-11-24 12:49:15 -07:00
modules_extra.rst Fixing a small typo 2015-09-16 11:00:19 -08:00
modules_intro.rst
playbooks.rst
playbooks_acceleration.rst - Fixed line break causing part of the text to display as "Definition List" 2015-08-27 21:41:36 -06:00
playbooks_async.rst
playbooks_best_practices.rst DOC: in yum examples, 'pkg' arg renamed to 'name' 2015-10-20 13:49:04 +02:00
playbooks_blocks.rst Update playbooks_blocks.rst 2015-10-07 14:26:23 -04:00
playbooks_checkmode.rst
playbooks_conditionals.rst made condition not simplifiable to 'in' 2015-11-01 16:31:23 -05:00
playbooks_delegation.rst removing confusing parts 2015-08-06 16:51:04 +03:00
playbooks_environment.rst Document setting environment variables in a playbook 2015-10-22 12:07:54 +01:00
playbooks_error_handling.rst clarified ignore_errors 2015-10-27 19:59:43 -04:00
playbooks_filters.rst Add an 'extract' filter 2015-12-02 18:16:38 +05:30
playbooks_filters_ipaddr.rst
playbooks_intro.rst Fix order of handlers that were notified in different sections 2015-10-21 11:00:47 +03:00
playbooks_lookups.rst Merge pull request #12881 from Scypho/devel 2015-11-12 15:39:35 -08:00
playbooks_loops.rst Merge pull request #13382 from mscherer/doc_with_inventory 2015-12-01 18:33:59 -08:00
playbooks_prompts.rst
playbooks_roles.rst Clarify how tagged roles work 2015-11-02 11:47:18 -05:00
playbooks_special_topics.rst
playbooks_startnstep.rst
playbooks_strategies.rst Fixed docs typo 2015-10-20 16:38:16 +01:00
playbooks_tags.rst Update playbooks_tags.rst 2015-08-11 13:20:48 +01:00
playbooks_variables.rst v1 variable precedence order was off. 2015-11-06 13:48:35 -05:00
playbooks_vault.rst vault and variables best practices info added, edited, and referenced 2015-10-15 09:55:17 -04:00
quickstart.rst
test_strategies.rst
tower.rst
YAMLSyntax.rst Added missing closing quote 2015-12-01 17:30:43 +05:30