2014-08-07 18:06:14 +02:00
|
|
|
local uci = luci.model.uci.cursor()
|
|
|
|
local meshvpn_enabled = uci:get("fastd", "mesh_vpn", "enabled", "0")
|
|
|
|
|
|
|
|
if meshvpn_enabled == "1" then
|
|
|
|
return nil
|
|
|
|
else
|
2015-04-11 09:53:14 +02:00
|
|
|
local i18n = require "luci.i18n"
|
2014-08-07 18:06:14 +02:00
|
|
|
local site = require 'gluon.site_config'
|
|
|
|
local sysconfig = require 'gluon.sysconfig'
|
|
|
|
|
|
|
|
local hostname = uci:get_first("system", "system", "hostname")
|
|
|
|
|
2015-04-11 09:53:14 +02:00
|
|
|
local msg = [[<p>]] .. i18n.translate('gluon-config-mode:nopubkey') .. [[</p>]]
|
|
|
|
|
2014-08-07 18:06:14 +02:00
|
|
|
return function ()
|
|
|
|
luci.template.render_string(msg, { hostname=hostname
|
|
|
|
, site=site
|
|
|
|
, sysconfig=sysconfig
|
|
|
|
})
|
|
|
|
end
|
|
|
|
end
|