feat(37回调): 添加大区集中转发接口

This commit is contained in:
luying
2022-11-09 16:21:24 +08:00
parent 81f0997304
commit e442fa6e7c
8 changed files with 177 additions and 48 deletions

View File

@@ -0,0 +1,13 @@
import { EggAppConfig, EggAppInfo, PowerPartial } from 'egg';
import defaultConfig from './config.default';
export default (appInfo: EggAppInfo) => {
const config = {} as PowerPartial<EggAppConfig>;
config.middleware = [ 'parmsDecode', 'getIp', 'proxy' ];
// the return config will combines to EggAppConfig
return {
...defaultConfig(appInfo),
...config
};
};