mirror of
https://github.com/Telecominfraproject/wlan-ap.git
synced 2025-11-01 19:07:47 +00:00
ucentral-event: Add DVLAN uplink to dhcpsnoop
When an uplink interface is created for a DVLAN due to swconfig support, add this new interface to dhcpsnoop Signed-off-by: Paul White <paul@shasta.cloud>
This commit is contained in:
@@ -132,9 +132,12 @@ handlers = {
|
||||
name: 'eth0.' + notify.data.vlan_id,
|
||||
vlan: [ `${notify.data.vlan_id}:u` ]
|
||||
};
|
||||
|
||||
ubus.call('network.interface.up_none', 'add_device', msg);
|
||||
|
||||
msg = { 'devices': { } };
|
||||
msg['devices']['eth0.' + notify.data.vlan_id] = { 'ingress': true, 'egress': true };
|
||||
ubus.call('dhcpsnoop', 'add_devices', msg);
|
||||
|
||||
let cmd = 'swconfig dev ' + config.config.swconfig + ' vlan ' + notify.data.vlan_id + ' set ports \"' + join(' ', config.config.swconfig_ports) + '\"';
|
||||
system(cmd);
|
||||
system('swconfig dev ' + config.config.swconfig + ' set apply');
|
||||
|
||||
Reference in New Issue
Block a user