fix check and removing logs

This commit is contained in:
Сергей Гудаев 2023-06-17 01:46:22 +08:00
parent 4e573feb60
commit 1b230192ed

View File

@ -44,7 +44,7 @@ _remove_logs (){
files=($(find . -maxdepth 1 -mtime +3 -iname "*logs*" -o -mtime +3 -iname "*vm_lic*" -o -mtime +3 -iname "*vm_node*" -o -mtime +3 -iname "*short-logs*" ! -iname "get*log*.sh")); files=($(find . -maxdepth 1 -mtime +3 -iname "*logs*" -o -mtime +3 -iname "*vm_lic*" -o -mtime +3 -iname "*vm_node*" -o -mtime +3 -iname "*short-logs*" ! -iname "get*log*.sh"));
if [[ ${#files[@]} >0 ]];then if [[ ${#files[@]} >0 ]];then
echo "founded platform logs older than last 3 days"; echo "\n************* Founded platform logs older than last 3 days **********************\n";
for item in ${files[*]} for item in ${files[*]}
do do
# printf " %s\n" $item # printf " %s\n" $item