Merge pull request #29 from ohrensessel/add-sysconfig

Allow sysconfig variable to be used on reboot page
This commit is contained in:
Nils Schneider 2014-06-07 13:48:12 +02:00
commit 1d3e2e3d17
1 changed files with 2 additions and 1 deletions

View File

@ -52,6 +52,7 @@ function action_reboot()
local pubkey
local uci = luci.model.uci.cursor()
local meshvpn_enabled = uci:get("fastd", meshvpn_name, "enabled", "0")
local sysconfig = require 'gluon.sysconfig'
if meshvpn_enabled == "1" then
pubkey = configmode.get_fastd_pubkey(meshvpn_name)
end
@ -64,7 +65,7 @@ function action_reboot()
if nixio.fork() ~= 0 then
luci.template.render("gluon-config-mode/reboot",
{luci=luci, pubkey=pubkey, hostname=hostname, site=site})
{luci=luci, pubkey=pubkey, hostname=hostname, site=site, sysconfig=sysconfig})
else
debug.setfenv(io.stdout, debug.getfenv(io.open '/dev/null'))
io.stdout:close()