⚙ modified sys info api

This commit is contained in:
Jyotirmoy Bandyopadhayaya 2023-06-24 13:28:58 +05:30
parent 9525eb5202
commit f5c6c2fd4d
Signed by: bravo68web
GPG Key ID: F5671FD7BCB9917A
1 changed files with 4 additions and 13 deletions

View File

@ -1,3 +1,5 @@
import os from 'node:os';
export default class InfoService {
static async getSystemInfo() {
const sys = {
@ -7,19 +9,8 @@ export default class InfoService {
uptime: process.uptime(),
memoryUsage: process.memoryUsage(),
cpuUsage: process.cpuUsage(),
pid: process.pid,
ppid: process.ppid,
cwd: process.cwd(),
execPath: process.execPath,
execArgv: process.execArgv,
argv: process.argv,
env: process.env,
config: process.config,
title: process.title,
version: process.version,
versions: process.versions,
release: process.release,
features: process.features,
kernelVersion: os.release(),
hostname: os.hostname(),
};
return sys;