You've already forked crontab-ui
mirror of
https://github.com/alseambusher/crontab-ui.git
synced 2025-12-15 11:43:58 +08:00
new:dev:support run the jobs manually
This commit is contained in:
6
app.js
6
app.js
@@ -87,6 +87,12 @@ app.post(routes.remove, function(req, res) {
|
||||
res.end();
|
||||
});
|
||||
|
||||
// run a job
|
||||
app.post(routes.run, function(req, res) {
|
||||
crontab.runjob(req.body._id);
|
||||
res.end();
|
||||
});
|
||||
|
||||
// set crontab. Needs env_vars to be passed
|
||||
app.get(routes.crontab, function(req, res, next) {
|
||||
crontab.set_crontab(req.query.env_vars, function(err) {
|
||||
|
||||
Reference in New Issue
Block a user