Where does RACK log to?

前端 未结 3 2024
日久生厌
日久生厌 2021-02-07 14:29

I am running a sinatra app through RACK.

To which file does the activity get logged ? Also how can I set the log file path ?

3条回答
  •  不知归路
    2021-02-07 14:51

    The line of LOGGER = Logger.new("sinatra.log") in @include's answer above did not work for me.

    However, an alternative listed here (along with some helpful explanations) worked for me, tested with ruby 2.5.3 and sinatra 2.0.1.

    For additional info, that alternative is based on the structure presented in a Sinatra recipe.

提交回复
热议问题