We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hey guys! Seems like the delete_old function is unable to delete retained logs on Windows with these PM2 configs:
{ "apps": [{ "name": "server", "logDateFormat": "YYYY-MM-DD HH:mm:ss Z", "errorFile": "./logs/server-err.log", "outFile": "./logs/server-out.log", "mergeLogs": true, "script": "./index.js" }] }
The problems appears to be related to this line: var fileBaseName = file.substr(0, file.length - 4).split('/').pop() + "__";
On my machine the split fails because the path has "" and not "/".
Because of that the following line fails to match the path, and no file is queued for deletion: if (files[i].indexOf(fileBaseName) >= 0)
The text was updated successfully, but these errors were encountered:
pm2-logrotate
@jessety/pm2-logrotate
No branches or pull requests
Hey guys! Seems like the delete_old function is unable to delete retained logs on Windows with these PM2 configs:
{
"apps": [{
"name": "server",
"logDateFormat": "YYYY-MM-DD HH:mm:ss Z",
"errorFile": "./logs/server-err.log",
"outFile": "./logs/server-out.log",
"mergeLogs": true,
"script": "./index.js"
}]
}
The problems appears to be related to this line:
var fileBaseName = file.substr(0, file.length - 4).split('/').pop() + "__";
On my machine the split fails because the path has "" and not "/".
Because of that the following line fails to match the path, and no file is queued for deletion:
if (files[i].indexOf(fileBaseName) >= 0)
The text was updated successfully, but these errors were encountered: