mirror of
https://github.com/unraid/webgui.git
synced 2026-02-21 09:18:41 -06:00
WireGuard: delayed service update to avoid race condition
This commit is contained in:
@@ -130,7 +130,7 @@ $active = explode(' ',exec('wg show interfaces'));
|
||||
$autostart = explode(' ',@file_get_contents("$etc/autostart")?:'');
|
||||
$build = false;
|
||||
$script = "$docroot/webGui/scripts/upnp_port";
|
||||
$services = "$docroot/webGui/scripts/reload_services";
|
||||
$services = "$docroot/webGui/scripts/update_services";
|
||||
$template = "$docroot/webGui/WGX.page";
|
||||
$tower = _var($var,'NAME');
|
||||
$ethX = 'eth0';
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#!/bin/bash
|
||||
SERVICES="sshd avahidaemon samba rpc nfsd ntpd nginx"
|
||||
SERVICES="rpc nfsd ntpd nginx sshd avahidaemon samba"
|
||||
|
||||
if [[ -n $1 ]]; then
|
||||
[[ ! -e $1 ]] && touch $1 || exit 0
|
||||
|
||||
8
emhttp/plugins/dynamix/scripts/update_services
Normal file
8
emhttp/plugins/dynamix/scripts/update_services
Normal file
@@ -0,0 +1,8 @@
|
||||
#!/bin/bash
|
||||
job=/tmp/wgjob.tmp
|
||||
reload=/usr/local/emhttp/webGui/scripts/reload_services
|
||||
|
||||
rm -f $job
|
||||
echo "sleep 5;$reload $job"|at -M now 2>/dev/null
|
||||
exit 0
|
||||
|
||||
Reference in New Issue
Block a user