Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to roll log file daily in spring-boot application

I deployed a spring-boot application on CentOS 6.5.
The application is started by command 'service app start'.
Below is content of app.conf.

JAVA_HOME=/xxx
LOG_FOLDER=/xxx

I am confused that how to roll log file daily.
There is no logback.xml or any other logback configuration in application.properties.

like image 282
John Avatar asked May 24 '17 08:05

John


1 Answers

You can place new logback.xml and write your appenders accordingly and place it in classpath, the application.properties will automatically look for it.

For more info please refer doc
For appenders it is already answered here

like image 152
Niranjan Kumar Avatar answered Nov 14 '22 22:11

Niranjan Kumar