We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 67cae4a commit b28db41Copy full SHA for b28db41
server/cron_daily.php
@@ -115,11 +115,12 @@
115
if(@is_file($logfile)) {
116
// Compress yesterdays logfile
117
exec("gzip -c $logfile > $logfile.gz");
118
+ unlink($logfile);
119
}
120
121
// delete logfiles after 30 days
122
$month_ago = date("Ymd",time() - 86400 * 30);
- $logfile = escapeshellcmd($rec["document_root"].'/log/'.$yesterday.'-access.log.gz');
123
+ $logfile = escapeshellcmd($rec["document_root"].'/log/'.$month_ago.'-access.log.gz');
124
125
unlink($logfile);
126
0 commit comments