mirror of https://github.com/aredn/aredn.git
Updates to /etc/local/services no longer require reboot (#1119)
This commit is contained in:
parent
b1c85fa281
commit
6be1091ffb
|
@ -106,7 +106,8 @@ local changes = {
|
|||
dnsmasq = false,
|
||||
firewall = false,
|
||||
tunnels = false,
|
||||
wireless = false
|
||||
wireless = false,
|
||||
localservices = false
|
||||
}
|
||||
|
||||
function valid_config(config)
|
||||
|
@ -1109,7 +1110,7 @@ if sf then
|
|||
sf:close()
|
||||
local _, diff = filecopy("/tmp/local_services", "/etc/local/services", true)
|
||||
if diff then
|
||||
changes.reboot = true
|
||||
changes.localservices = true
|
||||
end
|
||||
os.remove("/tmp/local_services")
|
||||
nixio.fs.chmod("/etc/local/services", "777")
|
||||
|
|
|
@ -34,7 +34,7 @@ true <<'LICENSE'
|
|||
LICENSE
|
||||
|
||||
ROOT="/tmp/reboot-required"
|
||||
SERVICES="log system firewall network wireless dnsmasq tunnels manager olsrd"
|
||||
SERVICES="log system firewall network wireless dnsmasq tunnels manager olsrd localservices"
|
||||
|
||||
ignore=0
|
||||
force=0
|
||||
|
@ -72,6 +72,8 @@ do
|
|||
/etc/init.d/vtundsrv restart > /dev/null 2>&1
|
||||
elif [ $srv = "wireless" ]; then
|
||||
/sbin/wifi reload > /dev/null 2>&1
|
||||
elif [ $srv = "localservices" ]; then
|
||||
/etc/local/services > /dev/null 2>&1
|
||||
elif [ -x /etc/init.d/$srv ]; then
|
||||
/etc/init.d/$srv restart > /dev/null 2>&1
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue