config.default.js 721 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. 'use strict';
  2. module.exports = appInfo => {
  3. const config = (exports = {});
  4. // use for cookie sign key, should change to your own and keep security
  5. config.keys = appInfo.name + '_1517455121740_8202';
  6. // add your config here
  7. // config.middleware = [];
  8. config.cluster = {
  9. listen: {
  10. port: 8105
  11. }
  12. };
  13. config.errorMongo = {
  14. details: true
  15. };
  16. config.errorHanler = {
  17. details: true
  18. };
  19. // mongoose config
  20. config.mongoose = {
  21. url: 'mongodb://localhost:27017/cms',
  22. options: {
  23. user: 'root',
  24. pass: 'Ziyouyanfa#@!',
  25. authSource: 'admin',
  26. useNewUrlParser: true,
  27. useCreateIndex: true,
  28. useUnifiedTopology: true,
  29. }
  30. };
  31. return config;
  32. };