Q
Q
Qwyu_4iLofK2022-01-24 13:14:27
symfony
Qwyu_4iLofK, 2022-01-24 13:14:27

How to make cron run on a manual schedule?

Good day!

There is a table-entity `cron`, in which I specified the name `name`, and the execution time `time`, and the command (launched by shell) `command`. ( 3 fields) How to schedule cron to run?
There is mybuilder/cronos-bundle in `symfony`, but is it possible to take the execution time of tasks from the `cron` entity table?
Either run any continuous cron B (running every minute) that checks against the execution time `time` and execute the specified task. It is worth noting that if you do this, then along with cron B, the current cron A will be executed (runs once every five minutes). But I don't like this way, maybe there are other ways?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
Maxim Fedorov, 2022-01-24
@Qwyu_4iLofK

There is mybuilder/cronos-bundle in `symfony`, but is it possible to take the execution time of tasks from the `cron` entity table?

This bundle works like this:
- the command parses the annotations of the commands
- enters the schedule into the
cron

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question