Commit 250d1a5a authored by 智勇's avatar 智勇

ok

parent ff20ceb6
......@@ -4,7 +4,9 @@ var cproc = require('child_process')
var execSync = cproc.execSync
var jenkinsapi = require('jenkins-api')
var jenkins = jenkinsapi.init("http://qahome:qahome@192.168.4.2:8080/")
var jenkins_user_pwd = 'http://yong.zhi:Lianghuapai233@'
var jenkins = jenkinsapi.init(jenkins_user_pwd + "192.168.4.96:8080/")
// var jenkins = jenkinsapi.init("http://qahome:qahome@192.168.4.2:8080/")
var eos_host = 'eos.quantgroups.com'
let default_username = 'xyqb_query'
......@@ -334,8 +336,8 @@ exports.db_sync_query = async function () {
return new Promise(resolve => setTimeout(resolve, ms))
}
api_json = await requestPromise(req.location + "api/json")
console.log(22, api_json)
api_json = await requestPromise(jenkins_user_pwd + req.location.replace('http://', '') + "api/json")
// api_json = await requestPromise(req.location.replace('http://', '') + "api/json")
if (typeof api_json == 'string') {
if (api_json.indexOf("number") > 0) {
......@@ -352,9 +354,9 @@ exports.db_sync_query = async function () {
this.body = { code: "0001", msg: { status: "queue", building: true }, log: { body: "" } }
}
} else {
console.log("获取队列信息出错", req.location)
console.log(api_json)
console.log(typeof api_json)
this.body = { code: "0002", msg: api_json }
this.body = { code: "0002", msg: "获取队列信息出错" }
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment