modules/admin-full: restart radvd if needed
This commit is contained in:
parent
74c6fb4cd7
commit
02a67572f8
2 changed files with 11 additions and 0 deletions
|
@ -280,6 +280,12 @@ function iface_reconnect()
|
|||
end
|
||||
|
||||
luci.sys.call("env -i /sbin/ifup %q >/dev/null 2>/dev/null" % iface)
|
||||
|
||||
require "luci.fs"
|
||||
if luci.fs.access("/etc/config/radvd") then
|
||||
luci.sys.call("/etc/init.d/radvd restart >/dev/null 2>/dev/null")
|
||||
end
|
||||
|
||||
luci.http.status(200, "Reconnected")
|
||||
return
|
||||
end
|
||||
|
|
|
@ -22,6 +22,7 @@ arg[1] = arg[1] or ""
|
|||
|
||||
local has_dnsmasq = fs.access("/etc/config/dhcp")
|
||||
local has_firewall = fs.access("/etc/config/firewall")
|
||||
local has_radvd = fs.access("/etc/config/radvd")
|
||||
|
||||
local has_3g = fs.access("/usr/bin/gcom")
|
||||
local has_pptp = fs.access("/usr/sbin/pptp")
|
||||
|
@ -39,6 +40,10 @@ if has_firewall then
|
|||
m:chain("firewall")
|
||||
end
|
||||
|
||||
if has_radvd then
|
||||
m:chain("radvd")
|
||||
end
|
||||
|
||||
nw.init(m.uci)
|
||||
fw.init(m.uci)
|
||||
|
||||
|
|
Loading…
Reference in a new issue