add bridge and vlan support

This commit is contained in:
2026-03-25 15:25:02 +03:00
parent 45198209ab
commit 4c69be99e0
8 changed files with 244 additions and 53 deletions
+35
View File
@@ -0,0 +1,35 @@
meta:
id: "lab-bridge"
name: "L2 Bridge"
description: "Two hosts in separate networks joined by a Linux bridge at L2."
networks:
- name: net1
- name: net2
nodes:
- name: srv
role: host
interfaces:
eth1:
network: net1
ip: "10.0.0.1/24"
- name: client
role: host
interfaces:
eth1:
network: net2
ip: "10.0.0.2/24"
- name: bridge
role: switch
interfaces:
eth1:
network: net1
eth2:
network: net2
bridges:
- name: br0
stp: false
members: [eth1, eth2]
+6
View File
@@ -0,0 +1,6 @@
Name,Role,Adapter,Interface,Interface Type,Slave Interfaces,Network,VLAN,Network IP,Mask,Device IP,Default Gateway
srv,Host,Adapter1,eth1,,,net1,,10.0.0.0,/24,10.0.0.1,
client,Host,Adapter1,eth1,,,net2,,10.0.0.0,/24,10.0.0.2,
bridge,Switch,Adapter1,eth1,,,net1,,,,,
bridge,Switch,Adapter2,eth2,,,net2,,,,,
bridge,Switch,,br0,bridge,"eth1,eth2",,,,,,
1 Name Role Adapter Interface Interface Type Slave Interfaces Network VLAN Network IP Mask Device IP Default Gateway
2 srv Host Adapter1 eth1 net1 10.0.0.0 /24 10.0.0.1
3 client Host Adapter1 eth1 net2 10.0.0.0 /24 10.0.0.2
4 bridge Switch Adapter1 eth1 net1
5 bridge Switch Adapter2 eth2 net2
6 bridge Switch br0 bridge eth1,eth2