[PATCH luci] luci-mod-network: migrate macaddr during bridge migration

Rafał Miłecki zajec5 at gmail.com
Sun May 30 23:35:09 PDT 2021


From: Rafał Miłecki <rafal at milecki.pl>

Link: https://forum.openwrt.org/t/network-migration-21-02-0-rc2/97934
Signed-off-by: Rafał Miłecki <rafal at milecki.pl>
---
 .../htdocs/luci-static/resources/view/network/interfaces.js   | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/modules/luci-mod-network/htdocs/luci-static/resources/view/network/interfaces.js b/modules/luci-mod-network/htdocs/luci-static/resources/view/network/interfaces.js
index 5d7f237bb6..07627c4aff 100644
--- a/modules/luci-mod-network/htdocs/luci-static/resources/view/network/interfaces.js
+++ b/modules/luci-mod-network/htdocs/luci-static/resources/view/network/interfaces.js
@@ -326,12 +326,14 @@ return view.extend({
 			tasks.push(uci.callAdd('network', 'device', null, {
 				'name': device_name,
 				'type': 'bridge',
-				'ports': L.toArray(ns.ifname)
+				'ports': L.toArray(ns.ifname),
+				'macaddr': ns.macaddr
 			}));
 
 			tasks.push(uci.callSet('network', ns['.name'], {
 				'type': '',
 				'ifname': '',
+				'macaddr': '',
 				'device': device_name
 			}));
 		});
-- 
2.26.2




More information about the openwrt-devel mailing list