I have the following fact, and I would like to create a new fact that excludes ‘lo’. What is the proper way to go about this?
`
“ansible_interfaces”: [
“lo”,
“enp0s3”,
“enp0s8”,
“enp0s9”
],
`
My latest failed attempt, but gives an idea as to what I am looking for
`
- name: Set custom facts
set_fact:
devices: “{{ ansible_interfaces is not search(‘lo’) }}”
fatal: [rhel7]: FAILED! => {“msg”: “Unexpected templating type error occurred on ({{ ansible_interfaces is not search(‘lo’) }}): expected string or buffer”}
`