There is a simple recipe for this. No magic involved.
- name: Check if there is enough space assert: that: (ansible_mounts|selectattr("mount", "equalto", "/")|list)[0].size_available > need_space
When you have a lot of tests, the last thing you want is to copy-paste non-trivial code again and again.
Netlink is a special socket protocol for Linux for network-level configuration. Normally it’s used by iproute2 (/usr/bin/ip) to configure network interfaces, and it’s expected to be low-volume.
/usr/bin/ip
Short news: There is a way to access playbook level group_vars from testinfra, if playbook_dir is configured in ansible.cfg.
playbook_dir
ansible.cfg
If this too cryptic, here is a long explanation.
It’s a totally obscure topic for people outside ovs, you are free to ignore.
When a port is added in openvswitch, it gets a special ID for the sake of openflow operations (those, which are happen in ovs-ofctl). It’s called ofport . You can…
ovs-ofctl
ofport