#!/bin/bash | |
source ./clean-up.sh | |
{beforeClean} | |
cd /home/admin/OnosSystemTest/TestON/logs | |
{cleaning} | |
cd /var/lib/jenkins/workspace/OnosProdCHOpost | |
echo "Checking if there are jenkins-logs older than ${DAYS_OLD} days...." | |
for i in $(find . -mtime +${DAYS_OLD}) | |
do | |
echo -e "logs older than $DAYS_OLD are: " | |
echo $i | |
rm -rf $i | |
done | |
{afterClean} |