Closed GregBlow closed 1 month ago
Here's a quick example of a playbook that will print all the active network interfaces on each machine checked:
hosts: all remote_user: root
tasks:
name: List Network Interfaces shell: ip route show register: physical_interfaces_cmd changed_when: false check_mode: false
name: Show network interface details for each host debug: msg={{ physical_interfaces_cmd.stdout.split('\n') }}
Playbooks written and initial tests indicate they work. They can be run on the admin node, where the system installed Ansible it setup for them. They are in /home/stack/network-check-playbooks
The source for the playbooks is here: https://git.ecdf.ed.ac.uk/lsstuk-somerville/somerville-admin-tools-and-scripts/-/tree/main/Security_Scripts_and_Scans/network-check-playbooks
Develop a playbook of tests to confirm network settings are correct.