更新部署服务

This commit is contained in:
aixianling
2022-05-26 18:13:54 +08:00
parent 54c631f208
commit 06a9b238e7
3 changed files with 4 additions and 5 deletions

View File

@@ -10,7 +10,7 @@ module.exports = {
dbUtils.query(sql).then(res => {
let info = res?.[0]
if (info?.id) {
let path = `zips/${info.id}/dist`, zipPath = `./zips/${info.id}.zip`
let path = `${info.target}`, zipPath = `./zips/${info.id}.zip`
fse.removeSync(zipPath)
fse.pathExists(path, (err, exists) => {
console.log(`${path}=========>${exists}`)

View File

@@ -20,7 +20,7 @@ module.exports = {
console.log(err)
db.query(`update node_autodeploy set error='${err}' where id='${info.id}'`)
})
} else response.send({code: 1, err: "无法找到git信息"})
} else response.send({code: 1, err: "无法找到部署工程"})
}).catch(err => {
console.log(err)
response.send({code: 1, err: err.sqlMessage})