Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions files/image_config/interfaces/interfaces.j2
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ iface {{ name }} {{ 'inet' if prefix | ipv4 else 'inet6' }} static
allow-hotplug {{ member }}
iface {{ member }} inet manual
pre-up ifconfig {{ member }} up mtu 9100
post-up brctl addif {{ vlan }} {{ member }} || true
post-up brctl addif Vlan{{ VLAN[vlan]['vlanid'] }} {{ member }} || true
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

how do we assign a VLAN ID if the VLAN name is not a number?

post-down ifconfig {{ member }} down
#
{% endfor %}
Expand All @@ -87,8 +87,8 @@ iface {{ member }} inet manual
{% if VLAN_INTERFACE %}
# Vlan interfaces
{% for (name, prefix) in VLAN_INTERFACE.keys() | sort %}
auto {{ name }}
iface {{ name }} {{ 'inet' if prefix | ipv4 else 'inet6' }} static
auto Vlan{{ VLAN[name]['vlanid'] }}
iface Vlan{{ VLAN[name]['vlanid'] }} {{ 'inet' if prefix | ipv4 else 'inet6' }} static
bridge_ports none
address {{ prefix | ip }}
netmask {{ prefix | netmask if prefix | ipv4 else prefix | prefixlen }}
Expand Down