config.local.ts 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. import { MidwayConfig } from '@midwayjs/core';
  2. const ip = '127.0.0.1';
  3. const project = 'ball';
  4. const mongodb = 'count_match_v1';
  5. export default {
  6. // use for cookie sign key, should change to your own and keep security
  7. keys: '1686030936692_986',
  8. koa: {
  9. globalPrefix: `/${project}/v1/api`,
  10. },
  11. swagger: {
  12. swaggerPath: `/dev/${project}/v1/doc`,
  13. },
  14. mongoose: {
  15. dataSource: {
  16. default: {
  17. uri: `mongodb://${ip}:27017/${mongodb}`,
  18. options: {
  19. user: 'admin',
  20. pass: 'admin',
  21. authSource: 'admin',
  22. useNewUrlParser: true,
  23. },
  24. entities: ['./entity'],
  25. },
  26. },
  27. },
  28. redis: {
  29. client: {
  30. port: 6379, // Redis port
  31. host: '127.0.0.1', // Redis host
  32. password: '123456',
  33. db: 4,
  34. },
  35. },
  36. axios: {
  37. clients: {},
  38. },
  39. export: {
  40. root_path: 'D:\\temp',
  41. export_path: 'D:\\temp\\export',
  42. export_dir: 'export',
  43. patentInfo_dir: 'patentInfo',
  44. domain: 'http://broadcast.waityou24.cn',
  45. },
  46. } as MidwayConfig;