Default logging file for spring boot application

后端 未结 4 564
我寻月下人不归
我寻月下人不归 2020-12-24 12:20

I have set the logging level in the spring boot application in application.yml as: logging.level.com.Myapplicationname=DEBUG

The application is packaged and deplo

4条回答
  •  南笙
    南笙 (楼主)
    2020-12-24 12:36

    for those who are using spring boot 2.2.x you need to put this in configuration file

    logging.file.name='/var/log/app.log'
    

    or use this

    logging.file.path='/var/log'
    

    note that if you use logging.file.path it will writes spring.log to the specified directory. Names can be an exact location or relative to the current directory

提交回复
热议问题