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.
This commit is contained in:
Jose Diaz-Gonzalez committed 2023-08-05 10:58:57 -04:00
1 parent eb6f85f083
commit afc318526c
16 files changed
+329 -234

No files matched your search

+1 -1
View File
@@ -28,6 +28,6 @@ func ReportSingleApp(appName string, format string, infoFlag string) error {
}
func reportTasks(appName string) string {
c, _ := fetchCronEntries(appName)
c, _ := FetchCronEntries(appName)
return strconv.Itoa(len(c))
}