mirror of
https://github.com/mclueppers/xo-server.git
synced 2025-07-26 15:34:40 +02:00
Treat Dom0 differently than other VMs.
This commit is contained in:
parent
ee1d1f3852
commit
8f46aa2242
@ -213,6 +213,7 @@ final class Application extends Base
|
||||
|
||||
$vms = $mgr_vms->get(array(
|
||||
'resident_on' => $host->id,
|
||||
'is_control_domain' => false,
|
||||
));
|
||||
|
||||
$CPUs = array();
|
||||
@ -230,7 +231,9 @@ final class Application extends Base
|
||||
$memory = array(
|
||||
'free' => $metrics->memory_free,
|
||||
'total' => $metrics->memory_total,
|
||||
'per_VM' => array(),
|
||||
'per_VM' => array(
|
||||
'dom0' => $dom0->memory_dynamic_max,
|
||||
),
|
||||
);
|
||||
|
||||
$os_version = $dom0_guest_metrics
|
||||
@ -270,11 +273,14 @@ final class Application extends Base
|
||||
);
|
||||
}
|
||||
|
||||
$VMs = array();
|
||||
$VMs = array(
|
||||
'dom0' => array(
|
||||
'name' => 'Dom0',
|
||||
),
|
||||
);
|
||||
foreach ($vms as $VM)
|
||||
{
|
||||
$VMs[$VM->uuid] = array(
|
||||
'is_control_domain' => $VM->is_control_domain,
|
||||
'name' => $VM->name_label,
|
||||
);
|
||||
$memory['per_VM'][$VM->uuid] = $VM->memory_dynamic_max;
|
||||
|
Loading…
x
Reference in New Issue
Block a user