update
This commit is contained in:
parent
0ae20916cc
commit
24e0729fe6
@ -6,7 +6,7 @@ const fs = require('fs')
|
|||||||
const http = require('http')
|
const http = require('http')
|
||||||
const exec = require('child_process').exec
|
const exec = require('child_process').exec
|
||||||
const port = process.env.PORT || 3000
|
const port = process.env.PORT || 3000
|
||||||
const hostname = process.env.hostname || 'localhost'
|
const hostname = require('os').hostname()
|
||||||
const MEMINFO_FILE_PATH = '/proc/meminfo'
|
const MEMINFO_FILE_PATH = '/proc/meminfo'
|
||||||
const TEMPERATURE_FILE_PATH = '/sys/class/thermal/thermal_zone0/temp'
|
const TEMPERATURE_FILE_PATH = '/sys/class/thermal/thermal_zone0/temp'
|
||||||
const status = { hostname, cpu: { temperature: 0, load: 0 }, memory: { total: 0, available: 0 }, error: null }
|
const status = { hostname, cpu: { temperature: 0, load: 0 }, memory: { total: 0, available: 0 }, error: null }
|
||||||
|
Loading…
Reference in New Issue
Block a user