fix(worker): default to disk 0 if /host/root not found
In order to avoid displaying 0 disk space on some systems, we default to the first disk found
This commit is contained in:
parent
0f129a7809
commit
852128f551
1 changed files with 1 additions and 1 deletions
|
@ -37,7 +37,7 @@ export class SystemExecutors {
|
|||
}
|
||||
|
||||
const disks = await si.fsSize();
|
||||
const disk0 = disks.find((disk) => disk.mount.startsWith('/host/root'));
|
||||
const disk0 = disks.find((disk) => disk.mount.startsWith('/host/root')) || disks[0];
|
||||
|
||||
return {
|
||||
cpu: { load: currentLoad },
|
||||
|
|
Loading…
Reference in a new issue