How do I externalize log4j.xml,application properties and jar using spring boot?

173 Views Asked by At

I created a spring boot project and wanted to externalize log4j.xml, application property file and jar ,so that I can create a bat file and run the spring boot application through this command

1

There are 1 best solutions below

0
On BEST ANSWER

java -Dlog4j.configuration=file:/temp/log4j.xml -jar temp/ltstatus.jar -Dspring.config.location=temp/application.properties

Replace temp as your folder path