json_get_vars enable reset
+ if [ "$reset" -eq "1" ]; then
+ swconfig dev $name set reset
+ fi
+ swconfig dev $name set enable_vlan $enable
+
if json_is_a roles array; then
json_get_keys roles roles
json_select roles
json_select ..
if [ "$device" = "$lan_if" ]; then
- if [ "$reset" -eq "1" ]; then
- swconfig dev $name set reset
- fi
-
- swconfig dev $name set enable_vlan $enable
swconfig dev $name vlan $role set ports "$ports"
- swconfig dev $name set apply
fi
done
json_select ..
fi
+ swconfig dev $name set apply
+
json_select ..
json_select ..
}