extended '/info' endpoint
This commit is contained in:
parent
2ca7834ba0
commit
ce81de43e6
1 changed files with 7 additions and 1 deletions
|
@ -18,13 +18,17 @@ function getLoadAverage(index) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function getArchitecture() {
|
function getArchitecture() {
|
||||||
return os.arch;
|
return os.arch();
|
||||||
}
|
}
|
||||||
|
|
||||||
function getOperatingSystem() {
|
function getOperatingSystem() {
|
||||||
return os.release();
|
return os.release();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function getType() {
|
||||||
|
return os.type();
|
||||||
|
}
|
||||||
|
|
||||||
function getPlatform() {
|
function getPlatform() {
|
||||||
return os.platform();
|
return os.platform();
|
||||||
}
|
}
|
||||||
|
@ -54,6 +58,7 @@ function getHostInfo() {
|
||||||
load: getLoadAverage(),
|
load: getLoadAverage(),
|
||||||
arch: getArchitecture(),
|
arch: getArchitecture(),
|
||||||
os: getOperatingSystem(),
|
os: getOperatingSystem(),
|
||||||
|
type: getType(),
|
||||||
platform: getPlatform(),
|
platform: getPlatform(),
|
||||||
kernel: getKernelVersion(),
|
kernel: getKernelVersion(),
|
||||||
cpu: getCpuInfo(),
|
cpu: getCpuInfo(),
|
||||||
|
@ -67,6 +72,7 @@ module.exports = {
|
||||||
getLoadAverage,
|
getLoadAverage,
|
||||||
getArchitecture,
|
getArchitecture,
|
||||||
getOperatingSystem,
|
getOperatingSystem,
|
||||||
|
getType,
|
||||||
getPlatform,
|
getPlatform,
|
||||||
getKernelVersion,
|
getKernelVersion,
|
||||||
getCpuInfo,
|
getCpuInfo,
|
||||||
|
|
Loading…
Reference in a new issue