Commit fb07dc83 authored by wolfsack's avatar wolfsack
Browse files

Update metrics.py

parent 2bb0087e
......@@ -73,14 +73,17 @@ def metrics():
}
)]
print(os.name)
print(platform.system())
# raspberry pi exclusive
if platform.system() == "Linux":
vcgm = Vcgencmd()
temp = vcgm.measure_temp()
print(temp)
temp = Vcgencmd().measure_temp()
metrics_list.append(
Metric(
metric_name="cpu_temperature",
metric_type="gauge",
comment="CPU Temperature",
value=temp,
params=None
))
for partition in partitions:
disk = psutil.disk_usage(partition[1])
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment