Globally reduce copyright headers
[project/luci.git] / protocols / luci-proto-ipv6 / luasrc / model / cbi / admin_network / proto_dhcpv6.lua
1 -- Copyright 2013 Steven Barth <steven@midlink.org>
2 -- Licensed to the public under the Apache License 2.0.
3
4 local map, section, net = ...
5
6
7 local o = section:taboption("general", ListValue, "reqaddress",
8         translate("Request IPv6-address"))
9 o:value("try")
10 o:value("force")
11 o:value("none", "disabled")
12 o.default = "try"
13
14
15 o = section:taboption("general", Value, "reqprefix",
16         translate("Request IPv6-prefix of length"))
17 o:value("auto", translate("automatic"))
18 o:value("no", translate("disabled"))
19 o:value("48")
20 o:value("52")
21 o:value("56")
22 o:value("60")
23 o:value("64")
24 o.default = "auto"
25
26
27 o = section:taboption("advanced", Flag, "defaultroute",
28         translate("Use default gateway"),
29         translate("If unchecked, no default route is configured"))
30 o.default = o.enabled
31
32
33 o = section:taboption("advanced", Flag, "peerdns",
34         translate("Use DNS servers advertised by peer"),
35         translate("If unchecked, the advertised DNS server addresses are ignored"))
36 o.default = o.enabled
37
38
39 o = section:taboption("advanced", Value, "ip6prefix",
40         translate("Custom delegated IPv6-prefix"))
41 o.dataype = "ip6addr"
42
43
44 o = section:taboption("advanced", DynamicList, "dns",
45         translate("Use custom DNS servers"))
46 o:depends("peerdns", "")
47 o.datatype = "list(ip6addr)"
48 o.cast     = "string"
49
50
51 o = section:taboption("advanced", Value, "clientid",
52         translate("Client ID to send when requesting DHCP"))
53
54 luci.tools.proto.opt_macaddr(section, ifc, translate("Override MAC address"))
55
56 o = section:taboption("advanced", Value, "mtu", translate("Override MTU"))
57 o.placeholder = "1500"
58 o.datatype    = "max(9200)"