kazana-config
v5.4.5
Published
Kazana core module for configuration
Downloads
35
Readme
kazana-config
Kazana core module for configuration
Usage
Kazana apps can be configured in 4 ways
config: {}
setting in the app / plugin manifestsmodule.exports = { name: 'myApp', version: '1.0.0', config: { kazana: { admin: { password: 'supersecret' } }, myApp: { mySetting: 'value' } } }
.kazanarc
files, using the rc package.[kazana.admin] password = supersecret [myApp] mySetting = value
Environment variables
kazana_kazana__admin__password='supersecret' kazana_myApp__mySetting=value npm start
command line arguments
npm start -- --kazana.admin.password='supersecret'
See https://www.npmjs.com/package/rc#standards for more details on how configuration is retrieved, and it what order.
The settings become available as server.settings.app.<setting path>
within
the app and the plugins, for example server.settings.app.kazana.admin.password
or server.settings.app.config.myApp.mySetting
Kazana Settings
Local setup and Testing
git clone [email protected]:eHealthAfrica/kazana-config.git
cd kazana-config
npm install
npm test
Test
npm test
Credit
Brought to you by eHealth Africa — good tech for hard places.