12345678910111213141516171819202122232425262728293031 |
- ---
- - name: Apply global configuration
- include_tasks: global_config.yml
- with_items: "{{ mellanox_switch_config }}"
- when: mellanox_switch_config is defined and mellanox_switch_config
- - name: Set empty dictionary if not defined
- set_fact:
- mellanox_switch_interface_config: {}
- when: mellanox_switch_interface_config is not defined or not mellanox_switch_interface_config
- - name: Apply interface configuration
- include_tasks: interface_config.yml
- with_dict: "{{ mellanox_switch_interface_config }}"
- loop_control:
- label: "{{ item.key }}"
- when: mellanox_switch_interface_config is defined and mellanox_switch_interface_config
|