Ansible variables help you reuse values across files in an Ansible project.
You can take advantage of inventory groups and the group_vars/ and host_vars/ directories to improve project maintainability.
Connection variables, such as ansible_connection and ansible_network_os, control how Ansible connects to a managed node.
The register keyword captures the output of a task in a variable.
Ansible facts are information about managed nodes that are stored in variables.
If the gather_facts keyword is set to true, then Ansible tries to automatically detect the network platform for each managed node and gather a minimal set of facts.
You can use *_facts resource modules to gather facts for your managed network nodes.
For example, use the cisco.ios.ios_facts module for Cisco IOS or IOS XE managed nodes, or the junipernetworks.junos.junos_facts module for Juniper Junos managed nodes.
Job template surveys help users to launch jobs with custom variable settings.
You can use filters in Jinja2 expressions and templates to format, transform, and parse data. You can apply multiple filters sequentially in the same expression.
The ansible.utils.ipaddr filter can process network address data into various output formats.