- Set cron by system user
sudo crontab -u username -e - Then add script for delete all log file after 3 days
0 0 * * * find /home/smap/webapps/ppa-smap-my/application/logs -name "log-*.php" -type f -mtime +1 -delete
sudo crontab -u username -e 0 0 * * * find /home/smap/webapps/ppa-smap-my/application/logs -name "log-*.php" -type f -mtime +1 -delete