up ip route add {{ route['network'] }} via {{ route['gateway'] }} || true
{% endfor %}
{% endif %}
{% endfor %}
{% endif %}
{% if bond_interfaces is defined and bond_interfaces != [] %}
{% for item in bond_interfaces %}
{% for slave in item['slaves'] %}
auto {{slave['name']}}
iface {{slave['name']}} inet manual
bond-master {{ item['name'] }}
{% endfor %}
auto {{ item['name'] }}
iface {{ item['name'] }} inet {% if item['dhcp'] is defined and item['dhcp']|lower == "true" %}dhcp{% else %}{% if item['ip_address'] is defined %}static
up ip route add {{ route['network'] }} via {{ route['gateway'] }} || true
{% endfor %}
{% endif %}
{% endfor %}
{% endif %}
{% if vlan_interfaces is defined and vlan_interfaces != [] %}
{% for item in vlan_interfaces %}
auto {{ item['name'] }}
iface {{ item['name'] }} inet {% if item['dhcp'] is defined and item['dhcp']|lower == "true" %}dhcp{% else %}{% if item['ip_address'] is defined %}static