Phoenix remove [debug] logging

对着背影说爱祢 提交于 2019-12-10 22:12:53

问题


When running a phoenix server, I am getting [debug] logs which I would like to not have (the logs in blue).

How can I alter my config to get rid of these


回答1:


You can set the log level in dev to be higher than debug which will make Logger not print any debug messages. The level just above debug is info. You can set that by adding this to config/dev.exs:

config :logger, level: :info

If you already have a config :logger line, you can just add level: :info at the end of it. You will have to restart your application for this to take effect.



来源:https://stackoverflow.com/questions/43004234/phoenix-remove-debug-logging

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!