Commit Graph

13 Commits

Author SHA1 Message Date
Jose Diaz-Gonzalez
7461b83972 fix: use correct makefile target 2025-11-09 23:16:38 -05:00
Jose Diaz-Gonzalez
f99e3a6c9c feat: add ability to suspend and resume a cron task by ID
This takes advantage of the properties system and allows users to suspend/resume the task at will.
2025-11-09 23:16:38 -05:00
Jose Diaz-Gonzalez
7e37f9dc79 fix: add missing trigger 2025-06-23 00:22:38 -04:00
Jose Diaz-Gonzalez
776013b0f4 fix: write the cron config after the app.json has been deleted
Without this, we try to write the config for the app even though it doesn't exist anymore, causing issues with deleting apps with invalid cron configs.
2025-06-19 01:09:15 -04:00
Jose Diaz-Gonzalez
36da77a2ff fix: write cron in pre-delete phase 2025-06-10 21:46:07 -04:00
Jose Diaz-Gonzalez
c0eb12f572 feat: add ability to set maintenance mode for all cron tasks running for an app
Closes #6953
2025-06-08 22:34:47 -04:00
Jose Diaz-Gonzalez
c36f23b072 fix: add missing cron:set command
The code existed but somehow it wasn't exposed as a command.

Closes #6655
2024-03-06 01:56:25 -05:00
Jose Diaz-Gonzalez
c23e878e7d feat: add the ability to specify a custom mailto for all cron output 2023-10-15 20:25:09 -04:00
Jose Diaz-Gonzalez
515994c8d3 feat: add the ability to execute a cron task on the fly
Closes #4904
2023-08-05 10:58:57 -04:00
Jose Diaz-Gonzalez
afc318526c refactor: move crontab writing code to scheduler-docker-local plugin
The implementation was very heavily docker-local specific and thus didn't make a ton of sense to keep in the cron plugin.

This also re-introduces changes from #5908 to parallelize the crontab generation (which is also specific to the docker-local scheduler) that were lost during a rebase.

The impetus for this change was implementing a `cron:run` command. The logic for actually running the command isn't scheduler specific - merely invoking `dokku run` with the appropriate arguments - but all the logic around how the commands were retrieved were, so the change was made pre-emptively.
2023-08-05 10:58:57 -04:00
Jose Diaz-Gonzalez
257baa1d46 refactor: run crontab under sudo to support rhel systems
RHEL blocks users from executing crontab as themselves Because Of Reasons so we need to use sudo instead.

Also refactors file writing to properly support writing the permissions on sudoers files going forward.

Closes #5020
2022-02-27 19:17:04 -05:00
Jose Diaz-Gonzalez
be84325de1 feat: add support for injected cron entries
This allows alternative plugins - such as dokku-letsencrypt - to inject scheduled cron tasks into the cron system used by Dokku. Cron systems can choose to include or not include a cron task based on the specified scheduler, and can also optionally use a third parameter to store arbitrary information.
2021-02-07 16:45:34 -05:00
Jose Diaz-Gonzalez
f7ef14d737 feat: add initial scheduled task implementation
This functionality enables users to manage a global crontab for the Dokku user that contains all scheduled tasks across all apps. Alternative schedulers can implement cron tasks as desired.
2021-01-20 14:49:48 -05:00