diff --git a/tasks/RedHat/8.yaml b/tasks/RedHat/8.yaml index dac3d35..d73b661 100644 --- a/tasks/RedHat/8.yaml +++ b/tasks/RedHat/8.yaml @@ -9,6 +9,16 @@ when: network.network_scripts is defined +- name: Set blank routes symbol + command: echo -n + register: echo + changed_when: false + +- name: Create array for interfaces to reload + set_fact: + reload_interfaces: [] + changed_when: false + - name: Configure interfaces and routes with nmcli include: network_manager.yaml iface={{ item }} when: network.network_manager is defined diff --git a/tasks/RedHat/network_manager.yaml b/tasks/RedHat/network_manager.yaml index b3bf5b1..79d43c1 100644 --- a/tasks/RedHat/network_manager.yaml +++ b/tasks/RedHat/network_manager.yaml @@ -15,6 +15,8 @@ state: present notify: - Reload interface with nmcli + set_fact: + reload_interfaces: "{{ reload_interfaces + iface.conn_name }}" - name: Get existing ipv4 routes shell: nmcli -g ipv4.routes connection show {{ iface.conn_name }}