iamolegga / nestjs-pino

Platform agnostic logger for NestJS based on Pino with REQUEST CONTEXT IN EVERY LOG
MIT License
1.26k stars 98 forks source link

[Daily log rotation] #744

Closed riteshkhatri closed 2 years ago

riteshkhatri commented 2 years ago

[ ] I've read the docs of nestjs-pino

[ ] I've read the docs of pino

[ ] I couldn't find the same question about nestjs-pino

Is there a way to make Synchronous configuration With Log rotation on daily basis just like [pino] (https://github.com/pinojs/pino) supports

Hello, I have used nestjs pino logger with Synchronous configuration and the package is realy nice. But i have one requirement I want to save the logs in every day new destination file which is similar to pino - log rotation (https://github.com/pinojs/pino/blob/master/docs/help.md#rotate). Is there any way to provide support like this?

iamolegga commented 2 years ago

Didn't get the question. If pino supports log rotation via config, just pass it via config of current module. If you're going to do log rotation as a separate process, then there are no matter of it's nestjs server or any other. Closing, the question is not related to this lib

subashdbc commented 2 years ago

@riteshkhatri Have you found any solution for creating logs every day with nestjs-pino?