I use Spring Boot and want it to write log output to a file.
According to the docs, this is simply done by setting
logging.file=filename.log
While the console output works fine, filename.log
is not created. Also, if I create the file manually, nothing is written to it. What do I miss?
Use logging.file.name
instead of logging.file
In higher versions of spring-boot-parent(from version 2.2.0)
, property logging.file is deprecated.