Line: 1 to 1 | ||||||||
---|---|---|---|---|---|---|---|---|
Ansible tips & tricks | ||||||||
Line: 61 to 61 | ||||||||
Use "{{ variable | selectattr('key_name', 'match', 'value') | list }}" Instead of match, you can also use search or regex. See: https://docs.ansible.com/ansible/latest/user_guide/playbooks_tests.html#testing-strings | ||||||||
Added: | ||||||||
> > | See the Jinja2 documentation for a list of available tests: https://jinja.palletsprojects.com/en/2.9.x/templates/#list-of-builtin-tests | |||||||
Sort list of dictionaries by subitem |