diff --git a/docs/docsite/rst/user_guide/complex_data_manipulation.rst b/docs/docsite/rst/user_guide/complex_data_manipulation.rst index 87c4f75d153..9f10984a250 100644 --- a/docs/docsite/rst/user_guide/complex_data_manipulation.rst +++ b/docs/docsite/rst/user_guide/complex_data_manipulation.rst @@ -94,6 +94,13 @@ There are several ways to do it in Ansible, this is just one example: } +.. code-block:: YAML+Jinja + :caption: Get the unique list of values of a variable that vary per host + + vars: + unique_value_list: "{{ groups['all'] | map ('extract', hostvars, 'varname') | list | unique}}" + + .. _find_mount_point: Find mount point