|
|
@ -37,6 +37,7 @@ args.option('clickHouseAnxincloud', 'clickHouse 安心云数据库名称'); |
|
|
|
args.option('clickHousePepEmis', 'clickHouse 项企数据库名称'); |
|
|
|
args.option('clickHouseProjectManage', 'clickHouse 项目管理数据库名称'); |
|
|
|
args.option('clickHouseVcmp', 'clickHouse 视频平台数据库名称'); |
|
|
|
args.option('clickHouseDataAlarm', 'clickHouse 视频平台数据告警库名称'); |
|
|
|
|
|
|
|
const flags = args.parse(process.argv); |
|
|
|
|
|
|
@ -75,6 +76,7 @@ const CLICKHOUST_ANXINCLOUD = process.env.CLICKHOUST_ANXINCLOUD || flags.clickHo |
|
|
|
const CLICKHOUST_PEP_EMIS = process.env.CLICKHOUST_PEP_EMIS || flags.clickHousePepEmis |
|
|
|
const CLICKHOUST_PROJECT_MANAGE = process.env.CLICKHOUST_PROJECT_MANAGE || flags.clickHouseProjectManage |
|
|
|
const CLICKHOUST_VCMP = process.env.CLICKHOUST_VCMP || flags.clickHouseVcmp |
|
|
|
const CLICKHOUST_DATA_ALARM = process.env.CLICKHOUST_DATA_ALARM || flags.clickHouseDataAlarm |
|
|
|
|
|
|
|
if ( |
|
|
|
!POMS_DB |
|
|
@ -84,7 +86,7 @@ if ( |
|
|
|
|| !API_EMIS_URL |
|
|
|
|| !QINIU_DOMAIN_QNDMN_RESOURCE || !QINIU_BUCKET_RESOURCE || !QINIU_AK || !QINIU_SK |
|
|
|
|| !CLICKHOUST_URL || !CLICKHOUST_PORT |
|
|
|
|| !CLICKHOUST_ANXINCLOUD || !CLICKHOUST_PEP_EMIS || !CLICKHOUST_PROJECT_MANAGE || !CLICKHOUST_VCMP |
|
|
|
|| !CLICKHOUST_ANXINCLOUD || !CLICKHOUST_PEP_EMIS || !CLICKHOUST_PROJECT_MANAGE || !CLICKHOUST_VCMP || !CLICKHOUST_DATA_ALARM |
|
|
|
) { |
|
|
|
console.log('缺少启动参数,异常退出'); |
|
|
|
args.showHelp(); |
|
|
@ -159,19 +161,24 @@ const product = { |
|
|
|
port: CLICKHOUST_PORT, |
|
|
|
user: CLICKHOUST_USER, |
|
|
|
password: CLICKHOUST_PASSWORD, |
|
|
|
db: [{ |
|
|
|
name: 'anxinyun', |
|
|
|
db: CLICKHOUST_ANXINCLOUD |
|
|
|
}, { |
|
|
|
name: 'pepEmis', |
|
|
|
db: CLICKHOUST_PEP_EMIS |
|
|
|
}, { |
|
|
|
name: 'projectManage', |
|
|
|
db: CLICKHOUST_PROJECT_MANAGE |
|
|
|
}, { |
|
|
|
name: 'vcmp', |
|
|
|
db: CLICKHOUST_VCMP |
|
|
|
},] |
|
|
|
db: [ |
|
|
|
{ |
|
|
|
name: 'anxinyun', |
|
|
|
db: CLICKHOUST_ANXINCLOUD |
|
|
|
}, { |
|
|
|
name: 'pepEmis', |
|
|
|
db: CLICKHOUST_PEP_EMIS |
|
|
|
}, { |
|
|
|
name: 'projectManage', |
|
|
|
db: CLICKHOUST_PROJECT_MANAGE |
|
|
|
}, { |
|
|
|
name: 'vcmp', |
|
|
|
db: CLICKHOUST_VCMP |
|
|
|
}, { |
|
|
|
name: 'dataAlarm', |
|
|
|
db: CLICKHOUST_DATA_ALARM |
|
|
|
} |
|
|
|
] |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|