Environment :
OS : SUSE Linux Enterprise Server 15 SP2 Node: 14.16.0 Express: 4.17.1, winston: 3.2.1, winston-daily-rotate-file: 4.4.2
I am using following code :
var transport = new (winston.transports.DailyRotateFile)({
filename: 'log/server-%DATE%.log',
datePattern: 'YYYY-MM-DD-HH',
maxSize: '100m', //100MB
zippedArchive: true,
maxFiles: '10',
frequency: '24h'
});
and getting error from crypto submodule of nodejs as "Digest method not supported"
Below is actual line which was throwing error from File "FileStreamRotator.js" under node_modules : crypto.createHash('md5').update(logfile + "LOG_FILE" + time).digest("hex")
Can someone please help to identify the issue here and probable solution?
Issue raised in winston-daily-rotate-file (This has been closed as actual issue is in file-stream-rotator and dependent crypto submodule of nodejs ) : https://github.com/winstonjs/winston-daily-rotate-file/issues/340
Raised the question in file-stream-rotator repo : https://github.com/rogerc/file-stream-rotator/issues/90