Merge pull request #1735 from sumpfralle/olsr-jsoninfo-parser-handle-empty-result
[oweals/luci.git] / applications / luci-app-openvpn / luasrc / model / cbi / openvpn-basic.lua
index cee5f9d31d3982f05a6bdd5edfb48129736ef013..86a76d5c8da85d73b62ce0340646856f17de4e97 100644 (file)
@@ -39,6 +39,10 @@ local basicParams = {
                "nobind",
                0,
                translate("Do not bind to local address and port") },
+       { ListValue,
+               "comp_lzo",
+               {"yes","no","adaptive"},
+               translate("Use fast LZO compression") },
        { Value,
                "keepalive",
                "10 60",
@@ -87,15 +91,11 @@ local basicParams = {
                "key",
                "/etc/easy-rsa/keys/some-client.key",
                translate("Local private key") },
-       { Value,
-               "config",
-               "/etc/openvpn/ovpn-file.ovpn",
-               translate("Local OVPN configuration file") },
 }
 
 
 local m = Map("openvpn")
-m.redirect = luci.dispatcher.build_url("admin", "services", "openvpn")
+m.redirect = luci.dispatcher.build_url("admin", "vpn", "openvpn")
 m.apply_on_parse = true
 
 local p = m:section( SimpleSection )
@@ -148,6 +148,8 @@ for _, option in ipairs(basicParams) do
                        end
                        return AbstractValue.remove(self, section)
                end
+       elseif option[1] == Flag then
+               o.default = nil
        else
                if option[1] == DynamicList then
                        function o.cfgvalue(...)