4a815deb27
Let environment variables override configuration set by config.json and/or app.set() Behavior changes - datasources.json now support dynamic configuration through env-vars and config.json - component-config.json will first consider env-var for resolving dynamic conf, then fallback to config.json - middleware.json will first consider env-var for resolving dynamic conf, then fallback to config.json - for all the dynamic confg, unresolved conf will return as `undefined` Example: Consider the following server/datasources.json ``` { "mysql" : { "name" : "mysql_db", "host" : "${MYSQL_DB_HOST}", ... } } ``` Now you can provide the parameter through an environment variable: ``` $ MYSQL_DB_HOST=127.0.0.1 node . ``` or you can set the value in server/config.json ``` { "MYSQL_DB_HOST": "127.0.0.1" } ``` |
||
---|---|---|
.. | ||
bundler.js | ||
compiler.js | ||
config-loader.js | ||
executor.js |