Log DIMM temperatures on each check run
All checks were successful
Check Flake / check-flake (push) Successful in 3m58s
All checks were successful
Check Flake / check-flake (push) Successful in 3m58s
This commit is contained in:
@@ -9,6 +9,7 @@ let
|
||||
|
||||
threshold=55
|
||||
hot=""
|
||||
summary=""
|
||||
|
||||
while IFS= read -r line; do
|
||||
case "$line" in
|
||||
@@ -18,6 +19,7 @@ let
|
||||
*temp1_input:*)
|
||||
temp="''${line##*: }"
|
||||
whole="''${temp%%.*}"
|
||||
summary="''${summary:+$summary, }$chip: ''${temp}°C"
|
||||
if [ "$whole" -ge "$threshold" ]; then
|
||||
hot="$hot"$'\n'" $chip: ''${temp}°C"
|
||||
fi
|
||||
@@ -25,6 +27,8 @@ let
|
||||
esac
|
||||
done < <(sensors -u 'spd5118-*' 2>/dev/null)
|
||||
|
||||
echo "$summary"
|
||||
|
||||
if [ -n "$hot" ]; then
|
||||
message="DIMM temperature above ''${threshold}°C on ${config.networking.hostName}:$hot"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user