MicroProfile Config
MicroProfile Config defines a set of supported default ConfigSources
for environment variables, system properties, and META-INF/microprofile-config.properties
files on the classpath with specific ordinals.
SmallRye Config library
Magnolia can scan more locations for configuration properties files and uses the SmallRye Config library for implementation.
It supports passing such locations through the magnolia.config.locations
configuration property, which is defined as a system or environment property.
-Dmagnolia.config.locations=../WEB-INF/config/default/microprofile-config.yaml
To specify the path on Windows, write it as a URI, as shown below.
-Dmagnolia.config.locations=file:///c:/magnolia/.../WEB-INF/config/default/microprofile-config.yaml
You can also specify locations via magnolia.properties file
|
This enables developers to build containerized images of Magnolia once, and deploy anywhere; for example, when using Docker bind mounts or Kubernetes ConfigMaps.