system() added uuid freebsd
This commit is contained in:
parent
39db1b6f8a
commit
c1d26c9a00
@ -120,6 +120,14 @@ function system(callback) {
|
||||
util.noop();
|
||||
}
|
||||
}
|
||||
if (!result.uuid && (_freebsd || _openbsd || _netbsd)) {
|
||||
try {
|
||||
const disksById = execSync('sysctl -i kern.hostid kern.hostuuid', util.execOptsLinux).toString();
|
||||
result.uuid = util.getValue(lines, 'kern.hostid', ':').toLowerCase();
|
||||
} catch (e) {
|
||||
util.noop();
|
||||
}
|
||||
}
|
||||
if (!result.virtual && (os.release().toLowerCase().indexOf('microsoft') >= 0 || os.release().toLowerCase().endsWith('wsl2'))) {
|
||||
const kernelVersion = parseFloat(os.release().toLowerCase());
|
||||
result.virtual = true;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user