I have a Spring Boot app that will be deployed as a fat jar. It integrates with Atlassian's Crowd for authentication. This requires a crowd.properties
file to be available on the classpath. I would prefer to not bundle the properties file (which includes a password) with the jar.
Is there a way to tell Spring Boot to include another file or directory for where to search for property files?
When doing this with a standalone/external Tomcat in the past, I would use the shared.loader
property in catalina.properties
to specify a directory where additional property files would be available.
I've tried including the file in the root location of the jar, as well as a /config
location, but to no avail. Atlassian also has a page that indicates using a -Dcrowd.properties=...
command line parameter to set this, but also to no avail.
Note: This is not referencing application.properties
in external locations.