sails logging to file

前端 未结 3 811
失恋的感觉
失恋的感觉 2020-12-25 13:27

Can someone provide an example of how to configure sails.js to log to a file?

It seems like it should be straightforward, but I\'m having trouble finding examples on

3条回答
  •  情歌与酒
    2020-12-25 14:19

    According to the source code, for v0.9.x, you just have to set the filePath in your config/log.js:

    module.exports = {
      log: {
        level: 'info',
        filePath: 'application.log'
      }
    };
    

提交回复
热议问题