Skip to content

How to add configuration settings

Guido Vilariño edited this page Oct 11, 2013 · 6 revisions

Since we don't track the config/development.json settings, new code that relies on config settings will break on other developers' environments if they don't update their settings as well after pulling. Follow this checklist whenever you need a new config value so the rest of us can continue coding happily with your changes.

After writing your new code and adding your config values to config/development.json, make sure you:

  1. Add those same values to config/sample.json
  2. Update config/env.json so when running on non-local environments the values are obtained from environment variables. Environment variables name should be the same as the config variable name but in ALL_CAPS. Follow the examples in that file.
  3. Add those value to env vars in your running environments so your new code works. DemocracyOS developers should update all of these.