Regarding the property resolution of SpringBoot explained here: https://docs.spring.io/spring-boot/docs/current/reference/html/boot-features-external-config.html
I want to exclude from the mechanism:
9. Java System properties (System.getProperties()).
10. OS environment variables.
Is it possible?
Thanks
You can provide your own implementation of
StandardEnvironmentwhen instancing your Spring Boot application.For example:
Or alternatively:
Either way, you ensure that your application's properties do not contain any system or environment properties.