We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6c62e29 commit 2b75830Copy full SHA for 2b75830
README.md
@@ -25,6 +25,7 @@ Example:
25
"name": "Windows",
26
"version": "10"
27
},
28
+ "uptime" : 231199,
29
"cpu_count": 4,
30
"cpu_usage": 17.9,
31
"memory_total": 8440942592,
monitor.py
@@ -52,11 +52,15 @@ def main():
52
53
# Time Info
54
timestamp = datetime.datetime.utcnow().strftime("%Y-%m-%d %H:%M:%S")
55
+ uptime = int(time.time() - psutil.boot_time())
56
+ print("System Uptime:")
57
+ print(uptime)
58
59
## Set Machine Info
60
machine = {
61
"hostname" : hostname,
62
"system" : system,
63
+ "uptime" : uptime,
64
"cpu_count" : cpu_count,
65
"cpu_usage" : cpu_usage,
66
"memory_total" : memory_total,
0 commit comments