electrode-io / electrode-confippet

node.js environment aware application configuration
Other
108 stars 18 forks source link

Cannot detect config files #19

Open pratikvarma opened 5 years ago

pratikvarma commented 5 years ago

I have tried adding a default.json, default.yaml under the config directory but keep getting this error:

Error: Config provider deployment: no file development of extensions json,yaml,js found in /myapp/config at load (/myapp/node_modules/electrode-confippet/lib/compose-config.js:36:17) at list.sort.forEach (/myapp/node_modules/electrode-confippet/lib/compose-config.js:87:9) at Array.forEach () at composeConfigDir (/myapp/node_modules/electrode-confippet/lib/compose-config.js:76:6) at dirs.forEach (/myapp/node_modules/electrode-confippet/lib/compose-config.js:107:5) at Array.forEach () at composeConfig (/myapp/node_modules/electrode-confippet/lib/compose-config.js:106:8) at Config.compose (/myapp/node_modules/electrode-confippet/lib/store.js:31:28) at load (/myapp/node_modules/electrode-confippet/lib/preset-config.js:31:13) at Object.autoLoad (/myapp/node_modules/electrode-confippet/lib/preset-config.js:40:5)

pratikvarma commented 5 years ago

It seems that a development.EXT file is necessary to be there if the NODE_ENV variable is not set. Is this a requirement? Also it seems this file cannot be empty if I want to just fallback to default instead.