Changeset 2175


Ignore:
Timestamp:
Sep 19, 2012, 3:26:05 PM (7 years ago)
Author:
matthijs
Message:

luci-openvpn: Allow changing max_clients setting.

The maximum number is 64, which is exactly the number of /30 IP blocks
fitting in the /24 network used (though this is probably a lot more than
the Foneras are actually capable of handling).

Thanks to Jon Spriggs for this patch.

Closes: #1178

Location:
trunk/luci
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/luci/applications/luci-openvpn/luasrc/model/cbi/openvpn/firewall.lua

    r2174 r2175  
    2828x.default = require("luci.model.uci").cursor():get("openvpn", "openvpn", "keepalive") or "10 120"
    2929
     30local x = s:option(ListValue, "max_clients", translate("openvpn_max_clients", "Concurrent Connections"))
     31x:value(1, 1)
     32x:value(2, 2)
     33x:value(4, 4)
     34x:value(8, 8)
     35x:value(16, 16)
     36x:value(32, 32)
     37x:value(64, 64)
     38x.default = require("luci.model.uci").cursor():get("openvpn", "openvpn", "max_clients") or 2
     39
    3040return m
  • trunk/luci/modules/admin-fon/root/sbin/save-config.sh

    r2174 r2175  
    121121echo "uci import -m openvpn <<EOF"
    122122echo "config 'openvpn' 'openvpn'"
    123 for o in enable lan wan keepalive; do
     123for o in enable lan wan keepalive max_clients; do
    124124        echo "  option '$o' '$(config_get openvpn $o)'"
    125125done
Note: See TracChangeset for help on using the changeset viewer.