ssh remote command of DEV_USAGE_CHECK.sh is much simpler now

This commit is contained in:
m8in
2026-06-18 20:45:56 +02:00
parent d5bb9abf8e
commit 7c8f9e1cfa
+2 -1
View File
@@ -5,7 +5,8 @@ base.loadModule ssh
function testSpace(){
local _RESULT=$(ssh.onHostRun "monitoring@${1:?"Missing REMOTE_HOST"}" 'df "/" | tail -n1 | tr -s "[:blank:]" " " | cut -d" " -f1,5')
local _RESPONSE=$(ssh.onHostRun "monitoring@${1:?"Missing REMOTE_HOST"}" 'df "/" | tail -n1')
local _RESULT=$(echo "${_RESPONSE}" | tr -s "[:blank:]" " " | cut -d" " -f1,5)
local _DEV=$(echo "${_RESULT}" | tail -n 1 | cut -d' ' -f1)
local _SPACE_USED=$(echo "${_RESULT}" | tail -n 1 | cut -d' ' -f2)