Compare commits

..

2 Commits

Author SHA1 Message Date
oleg 913d971663 progress 2024-07-16 12:11:37 -04:00
oleg 0f6d7874de progress 2024-06-13 19:40:49 -04:00
3 changed files with 12 additions and 14 deletions
+1 -1
View File
@@ -1 +1 @@
0.8.2.2
0.8.4
+1 -1
View File
@@ -11,7 +11,7 @@ then
CredKey=TSDB_MD_CVTTDATA_RO
elif [ "${host}" == "cloud21.cryptovaltrading.com" ]
then
ArchiveRootDir=/opt/store/cvtt/archive/md_archive
ArchiveRootDir=/opt/store/cvtt/crypto/md_archive
CredKey=TSDB_MD_CLD21_RO
else
echo "Unknown host ${host}. ${0} Aborted."
+10 -12
View File
@@ -38,20 +38,13 @@ Metrics=()
TempFiles=
function cleanup {
echo Cleaing up temporary files: ${TempFiles}
if [ "" != "${TempFiles}" ]; then
echo rm -f ${TempFiles}
rm -f ${TempFiles}
fi
}
trap cleanup EXIT
function new_tempfile {
tmpfile=$(mktemp)
TempFiles="${TempFiles} ${tmpfile}"
echo ${tmpfile}
}
function space_alert() {
ALERT_USAGE=75%
for metric in "${Metrics[@]}"
@@ -105,8 +98,12 @@ function storage_check() {
done
}
tmpfile=$(new_tempfile)
tmpfile2=$(new_tempfile)
tmpfile=$(mktemp)
TempFiles="${TempFiles} ${tmpfile}"
tmpfile2=$(mktemp)
TempFiles="${TempFiles} ${tmpfile2}"
storage_check > ${tmpfile2}
echo "## :card_file_box: STORAGE HEALTH CHECK" >> ${tmpfile}
@@ -116,8 +113,9 @@ echo "| --- | --- | --- |" >> ${tmpfile}
cat ${tmpfile2} | sort -h -r | awk -F'%' '{printf "%s%%%s\n",$2,$3}' >> ${tmpfile}
cat ${tmpfile} | ${Sender} ${StatusChannel}
Measurements=()
tmpfile=$(new_tempfile)
tmpfile=$(mktemp)
TempFiles="${TempFiles} ${tmpfile}"
space_alert > ${tmpfile}
if [ -s ${tmpfile} ]
then