mirror of
https://gitlab.silvrtree.co.uk/martind2000/nci.git
synced 2025-01-11 00:35:08 +00:00
do not queue already queued project by default
This commit is contained in:
parent
374b84adb2
commit
8c53e0e621
@ -67,7 +67,7 @@ module.exports = function(app) {
|
||||
app.distributor.run({
|
||||
projectName: projectName,
|
||||
withScmChangesOnly: req.body.withScmChangesOnly,
|
||||
skipQueued: req.body.skipQueued,
|
||||
queueTwice: req.body.queueTwice,
|
||||
initiator: {type: 'httpApi'}
|
||||
});
|
||||
} else {
|
||||
|
@ -115,7 +115,7 @@ Distributor.prototype._runNext = function(callback) {
|
||||
id: build.id,
|
||||
number: build.number,
|
||||
project: {name: build.project.name}
|
||||
},
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
@ -164,7 +164,7 @@ Distributor.prototype._onBuildComplete = function(build, callback) {
|
||||
id: build.id,
|
||||
number: build.number,
|
||||
project: {name: build.project.name}
|
||||
},
|
||||
}
|
||||
}, triggerAfterGroup.slot());
|
||||
}
|
||||
});
|
||||
@ -292,7 +292,7 @@ Distributor.prototype.run = function(params, callback) {
|
||||
return callback();
|
||||
}
|
||||
|
||||
if (params.skipQueued) {
|
||||
if (!params.queueTwice) {
|
||||
var queuedItem = _(self.queue).find(function(item) {
|
||||
return item.project.name === project.name;
|
||||
});
|
||||
|
@ -119,7 +119,8 @@ module.exports = function(app) {
|
||||
logger.log('Run the project: "%s"', projectName);
|
||||
distributor.run({
|
||||
projectName: projectName,
|
||||
initiator: {type: 'user'}
|
||||
initiator: {type: 'user'},
|
||||
queueTwice: true
|
||||
});
|
||||
res.send();
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user