How to enable BLOB-logging for a Node.js Api App on Azure?

前端 未结 2 1344
一生所求
一生所求 2020-12-02 03:30

I have a node.js api app on azure. I use bunyan to log every request to sdtout. How can I save and read the log files? I enabled BLOB-logging. The

相关标签:
2条回答
  • 2020-12-02 03:55

    After above settings in iisnode.yml, the logs you see D:\home\site\wwwroot\iisnode are from BLOB storage or file system.

    0 讨论(0)
  • 2020-12-02 03:59

    1) Create file iisnode.yml in your root folder (D:\home\site\wwwroot) if not exists.

    2) Add the following lines to it.

    loggingEnabled: true
    logDirectory: iisnode
    

    After that done, you can find logs in D:\home\site\wwwroot\iisnode.

    For more info, please refer to https://docs.microsoft.com/en-us/azure/app-service-web/web-sites-nodejs-debug#enable-logging.

    0 讨论(0)
提交回复
热议问题