mirror of
https://github.com/Ysurac/openmptcprouter-feeds.git
synced 2025-03-09 15:40:03 +00:00
Add macvlan support
This commit is contained in:
parent
40fdd921b9
commit
9f8643647e
255 changed files with 134998 additions and 0 deletions
67
luci-base/luasrc/model/cbi/admin_network/proto_dhcp.lua
Normal file
67
luci-base/luasrc/model/cbi/admin_network/proto_dhcp.lua
Normal file
|
@ -0,0 +1,67 @@
|
|||
-- Copyright 2011-2012 Jo-Philipp Wich <jow@openwrt.org>
|
||||
-- Licensed to the public under the Apache License 2.0.
|
||||
|
||||
local map, section, net = ...
|
||||
local ifc = net:get_interface()
|
||||
|
||||
local hostname, accept_ra, send_rs
|
||||
local bcast, defaultroute, peerdns, dns, metric, clientid, vendorclass
|
||||
|
||||
|
||||
hostname = section:taboption("general", Value, "hostname",
|
||||
translate("Hostname to send when requesting DHCP"))
|
||||
|
||||
hostname.placeholder = luci.sys.hostname()
|
||||
hostname.datatype = "hostname"
|
||||
|
||||
|
||||
bcast = section:taboption("advanced", Flag, "broadcast",
|
||||
translate("Use broadcast flag"),
|
||||
translate("Required for certain ISPs, e.g. Charter with DOCSIS 3"))
|
||||
|
||||
bcast.default = bcast.disabled
|
||||
|
||||
|
||||
defaultroute = section:taboption("advanced", Flag, "defaultroute",
|
||||
translate("Use default gateway"),
|
||||
translate("If unchecked, no default route is configured"))
|
||||
|
||||
defaultroute.default = defaultroute.enabled
|
||||
|
||||
|
||||
peerdns = section:taboption("advanced", Flag, "peerdns",
|
||||
translate("Use DNS servers advertised by peer"),
|
||||
translate("If unchecked, the advertised DNS server addresses are ignored"))
|
||||
|
||||
peerdns.default = peerdns.enabled
|
||||
|
||||
|
||||
dns = section:taboption("advanced", DynamicList, "dns",
|
||||
translate("Use custom DNS servers"))
|
||||
|
||||
dns:depends("peerdns", "")
|
||||
dns.datatype = "ipaddr"
|
||||
dns.cast = "string"
|
||||
|
||||
|
||||
metric = section:taboption("advanced", Value, "metric",
|
||||
translate("Use gateway metric"))
|
||||
|
||||
metric.placeholder = "0"
|
||||
metric.datatype = "uinteger"
|
||||
|
||||
|
||||
clientid = section:taboption("advanced", Value, "clientid",
|
||||
translate("Client ID to send when requesting DHCP"))
|
||||
|
||||
|
||||
vendorclass = section:taboption("advanced", Value, "vendorid",
|
||||
translate("Vendor Class to send when requesting DHCP"))
|
||||
|
||||
|
||||
luci.tools.proto.opt_macaddr(section, ifc, translate("Override MAC address"))
|
||||
|
||||
|
||||
mtu = section:taboption("advanced", Value, "mtu", translate("Override MTU"))
|
||||
mtu.placeholder = "1500"
|
||||
mtu.datatype = "max(9200)"
|
Loading…
Add table
Add a link
Reference in a new issue