filter plugins¶
This is the list of filter plugins in the ansible.utils collection:
| Plugin | Description |
|---|---|
| ansible.utils.cidr_merge | This filter can be used to merge subnets or individual addresses. |
| ansible.utils.consolidate | Consolidate facts together on common attributes. |
| ansible.utils.fact_diff | Find the difference between currently set facts |
| ansible.utils.from_xml | Convert given XML string to native python dictionary. |
| ansible.utils.get_path | Retrieve the value in a variable using a path |
| ansible.utils.hwaddr | HWaddr / MAC address filters |
| ansible.utils.index_of | Find the indices of items in a list matching some criteria |
| ansible.utils.ip4_hex | This filter is designed to convert IPv4 address to Hexadecimal notation with optional delimiter. |
| ansible.utils.ipaddr | This filter is designed to return the input value if a query is True, else False. |
| ansible.utils.ipcut | This filter is designed to get 1st or last few bits of IP address. |
| ansible.utils.ipmath | This filter is designed to do simple IP math/arithmetic. |
| ansible.utils.ipsubnet | This filter can be used to manipulate network subnets in several ways. |
| ansible.utils.ipv4 | To filter only Ipv4 addresses Ipv4 filter is used. |
| ansible.utils.ipv6 | To filter only Ipv6 addresses Ipv6 filter is used. |
| ansible.utils.ipv6form | This filter is designed to convert ipv6 address in different formats. For example expand, compressetc. |
| ansible.utils.ipwrap | This filter is designed to Wrap IPv6 addresses in [ ] brackets. |
| ansible.utils.keep_keys | Keep specific keys from a data recursively. |
| ansible.utils.macaddr | macaddr / MAC address filters |
| ansible.utils.network_in_network | This filter returns whether an address or a network passed as argument is in a network. |
| ansible.utils.network_in_usable | The network_in_usable filter returns whether an address passed as an argument is usable in a network. |
| ansible.utils.next_nth_usable | This filter returns the next nth usable ip within a network described by value. |
| ansible.utils.nthhost | This filter returns the nth host within a network described by value. |
| ansible.utils.param_list_compare | Generate the final param list combining/comparing base and provided parameters. |
| ansible.utils.previous_nth_usable | This filter returns the previous nth usable ip within a network described by value. |
| ansible.utils.reduce_on_network | This filter reduces a list of addresses to only the addresses that match a given network. |
| ansible.utils.remove_keys | Remove specific keys from a data recursively. |
| ansible.utils.replace_keys | Replaces specific keys with their after value from a data recursively. |
| ansible.utils.slaac | This filter returns the SLAAC address within a network for a given HW/MAC address. |
| ansible.utils.to_paths | Flatten a complex object into a dictionary of paths and values |
| ansible.utils.to_xml | Convert given JSON string to XML |
| ansible.utils.usable_range | Expand the usable IP addresses |
| ansible.utils.validate | Validate data with provided criteria |