Formatage , et gestion des igmp querier
This commit is contained in:
parent
4bac7c64dd
commit
827220a50a
2 changed files with 32 additions and 16 deletions
|
@ -44,25 +44,33 @@ vlan {{ id }}
|
|||
{%- if vlan["ports_untagged"] %}
|
||||
untagged {{ vlan["ports_untagged"]|join(',') }}
|
||||
{%- endif %}
|
||||
{%- for ipv4, subnet in switch.interfaces_subnet.items() %}
|
||||
{%- if subnet.0.vlan_id == id %}
|
||||
ip address {{ ipv4 }}/{{ subnet.0.netmask_cidr }}
|
||||
{%- endif %}
|
||||
{%- endfor %}
|
||||
{%- for ipv6, subnet6 in switch.interfaces6_subnet.items() %}
|
||||
{%- if subnet6.vlan_id == id %}
|
||||
ipv6 address {{ ipv6 }}/{{ subnet6.netmask_cidr }}
|
||||
{%- endif %}
|
||||
{%- endfor %}
|
||||
{%- if id in additionals.igmp_vlans %}
|
||||
ip igmp
|
||||
no ip igmp querier
|
||||
{%- endif %}
|
||||
{%- if id in additionals.mld_vlans %}
|
||||
no ipv6 mld querier
|
||||
ipv6 mld version 1
|
||||
ipv6 mld enable
|
||||
{%- endif %}
|
||||
{%- if vlan.ipv4 %}
|
||||
{%- for ipv4, subnet in vlan.ipv4.items() %}
|
||||
ip address {{ ipv4 }}/{{ subnet.0.netmask_cidr }}
|
||||
{%- endfor %}
|
||||
{%- else %}
|
||||
no ip address
|
||||
{%- endif %}
|
||||
{%- if vlan.ipv6 %}
|
||||
{%- for ipv6, subnet6 in vlan.ipv6.items() %}
|
||||
ipv6 address {{ ipv6 }}/{{ subnet6.netmask_cidr }}
|
||||
{%- endfor %}
|
||||
{%- else %}
|
||||
no ipv6 address
|
||||
{%- if id in additionals.igmp_vlans %}
|
||||
no ip igmp querier
|
||||
{%- endif %}
|
||||
{%- if id in additionals.mld_vlans %}
|
||||
no ipv6 mld querier
|
||||
{%- endif %}
|
||||
{%- endif %}
|
||||
exit
|
||||
{%- endfor %}
|
||||
;--- Accès d'administration ---
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue