config.js 465 B

1234567891011121314151617181920212223
  1. var config = {
  2. //REDISURL: getEnv('REDISURL'),
  3. //PORT: getEnv('PORT'),
  4. //FBID: getEnv('FBID'),
  5. //FBIDSECRET: getEnv('FBIDSECRET')
  6. };
  7. conf = {
  8. port: 3000,
  9. debug: false,
  10. dbPort: 6379,
  11. dbHost: '127.0.0.1',
  12. dbOptions: {}
  13. };
  14. function getEnv(variable){
  15. if (process.env[variable] === undefined){
  16. throw new Error('You must create an environment variable for ' + variable);
  17. }
  18. return process.env[variable];
  19. };
  20. module.exports = config;