mirror of
https://github.com/unraid/webgui.git
synced 2026-02-17 22:48:53 -06:00
Fix php error due to typo and if libvirt is not started.
This commit is contained in:
@@ -165,7 +165,7 @@ if ($_POST['vms']) {
|
||||
echo $vmhtml;
|
||||
}
|
||||
if (!count($vmusagehtml)) echo "<span id='no_usagevms'><br> "._('No running virtual machines')."<br></span>";
|
||||
if ($running < 1 && count($vmsusagehtml)) echo "<span id='no_usagevms'><br>". _('No running virtual machines')."<br></span>";
|
||||
if ($running < 1 && count($vmusagehtml)) echo "<span id='no_usagevms'><br>". _('No running virtual machines')."<br></span>";
|
||||
echo "</td></tr>";
|
||||
}
|
||||
}
|
||||
|
||||
@@ -20,6 +20,10 @@ require_once "$docroot/webGui/include/Helpers.php";
|
||||
require_once "$docroot/webGui/include/publish.php";
|
||||
require_once "$docroot/plugins/dynamix.vm.manager/include/libvirt_helpers.php";
|
||||
global $vmusagestats;
|
||||
exec("/etc/rc.d/rc.libvirt status >/dev/null",$dummy,$libvirtd);
|
||||
$libvirtd = $libvirtd==0;
|
||||
if (!$libvirtd) return;
|
||||
|
||||
extract(parse_plugin_cfg('dynamix',true));
|
||||
get_vm_usage_stats();
|
||||
sleep(1);
|
||||
|
||||
Reference in New Issue
Block a user