123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354 |
- "use strict";
- // 开发服务-生产环境
- module.exports = (appInfo) => {
- const config = (exports = {});
- // 数据库设置
- config.dbName = "point_shopping";
- config.mongoose = {
- url: `mongodb://127.0.0.1:27017/${config.dbName}`, // 120.48.146.1 127.0.0.1
- options: {
- user: "admin",
- pass: "admin",
- authSource: "admin",
- useNewUrlParser: true,
- useCreateIndex: true,
- useFindAndModify: true,
- },
- };
- // redis设置
- config.redis = {
- client: {
- port: 6379, // Redis port
- host: "127.0.0.1", // Redis host
- password: "123456",
- db: 1,
- },
- };
- // mq设置
- config.amqp = {
- client: {
- hostname: "127.0.0.1",
- username: "tehq",
- password: "tehq",
- vhost: "tehq",
- },
- app: true,
- agent: true,
- };
- // 定时任务机制设置
- config.taskMqConfig = {
- ex: "task",
- queue: "task",
- routingKey: "tr",
- deadEx: "deadTask",
- deadQueue: "deadTaskQueue",
- deadLetterRoutingKey: "deadTr",
- };
- config.logger = {
- level: "NONE",
- };
- return {
- ...config,
- };
- };
|