# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

source /etc/network/interfaces.d/*.intf

auto lo
iface lo inet loopback
    address 10.0.0.11/32
    vxlan-local-tunnelip 10.0.0.11

auto mgmt
iface mgmt
    address 127.0.0.1/8
    address 127.0.1.1/8
    address ::1/128
    vrf-table auto

auto TENANT_A
iface TENANT_A
    address 127.0.0.1/8
    address 127.0.1.1/8
    address ::1/128
    vrf-table auto

auto eth0
iface eth0 inet dhcp
    ip-forward off
    ip6-forward off
    vrf mgmt

auto bond1
iface bond1
    es-sys-mac 00:00:00:00:10:11
    bond-slaves swp7 swp8
    bond-mode 802.3ad
    bond-lacp-bypass-allow no
    bridge-access 10

auto bond3
iface bond3
    bond-mode 802.3ad
    bond-lacp-bypass-allow no

auto bond4
iface bond4
    es-sys-mac 00:00:00:00:00:11
    bond-slaves swp10 swp11
    bond-mode 802.3ad
    bond-lacp-bypass-allow no
    bridge-access 12

auto swp1
iface swp1

auto vxlan48
iface vxlan48
    vxlan-mcastgrp-map 10011=224.0.0.0
    bridge-vlan-vni-map 42=42 10=10010 11=10011
    bridge-learning off
    vxlan-port 4242
    vxlan-port 4242
    vxlan-port 4242

auto vlan926_l3
iface vlan926_l3
    vrf TENANT_A
    vlan-raw-device br_l3vni
    vlan-id 926

auto vxlan99
iface vxlan99
    bridge-vlan-vni-map 926=104001
    bridge-learning off
    vxlan-port 4242

auto br_default
iface br_default
    bridge-ports bond1 bond4 vxlan48
    bridge-vlan-aware yes
    bridge-vids 42 10 11
    bridge-pvid 1
    bridge-stp yes
    bridge-mcsnoop no
    mstpctl-forcevers rstp

auto br_l3vni
iface br_l3vni
    bridge-ports vxlan99
    bridge-vlan-aware yes
