|
@ -23,7 +23,7 @@ args.option('aliOssRegion', '阿里OSS Region'); |
|
|
|
|
|
|
|
|
const flags = args.parse(process.argv); |
|
|
const flags = args.parse(process.argv); |
|
|
|
|
|
|
|
|
const ZHONGDING_DB = process.env.ZHONGDING_DB || flags.pg; |
|
|
const XUNJIAN_DB = process.env.XUNJIAN_DB || flags.pg; |
|
|
|
|
|
|
|
|
// 七牛云存储参数
|
|
|
// 七牛云存储参数
|
|
|
const QINIU_DOMAIN_QNDMN_RESOURCE = process.env.ANXINCLOUD_QINIU_DOMAIN_QNDMN_RESOURCE || flags.qndmn; |
|
|
const QINIU_DOMAIN_QNDMN_RESOURCE = process.env.ANXINCLOUD_QINIU_DOMAIN_QNDMN_RESOURCE || flags.qndmn; |
|
@ -37,7 +37,7 @@ const ALI_OSS_SECRETKET = process.env.ALI_OSS_SECRETKET || flags.aliOssSecretKey |
|
|
const ALI_OSS_BUCKET = process.env.ALI_OSS_BUCKET || flags.aliOssBucket; |
|
|
const ALI_OSS_BUCKET = process.env.ALI_OSS_BUCKET || flags.aliOssBucket; |
|
|
const ALI_OSS_REGION = process.env.ALI_OSS_REGION || flags.aliOssRegion; |
|
|
const ALI_OSS_REGION = process.env.ALI_OSS_REGION || flags.aliOssRegion; |
|
|
|
|
|
|
|
|
if (!ZHONGDING_DB || !QINIU_DOMAIN_QNDMN_RESOURCE || !QINIU_BUCKET_RESOURCE || !QINIU_AK || !QINIU_SK) { |
|
|
if (!XUNJIAN_DB || !QINIU_DOMAIN_QNDMN_RESOURCE || !QINIU_BUCKET_RESOURCE || !QINIU_AK || !QINIU_SK) { |
|
|
console.log('缺少启动参数,异常退出'); |
|
|
console.log('缺少启动参数,异常退出'); |
|
|
args.showHelp(); |
|
|
args.showHelp(); |
|
|
process.exit(-1); |
|
|
process.exit(-1); |
|
@ -96,7 +96,7 @@ const product = { |
|
|
} |
|
|
} |
|
|
], |
|
|
], |
|
|
dc: { |
|
|
dc: { |
|
|
url: ZHONGDING_DB, |
|
|
url: XUNJIAN_DB, |
|
|
opts: { |
|
|
opts: { |
|
|
pool: { |
|
|
pool: { |
|
|
max: 80, |
|
|
max: 80, |
|
|