5 Commits

Author SHA1 Message Date
Jose Diaz-Gonzalez
58042b9330 feat: delegate storage:exec to scheduler plugins, harden the flow
Moves the actual exec out of the storage plugin and into a new scheduler-storage-exec plugn trigger. scheduler-docker-local does docker run with TTY-aware -it/-i selection and --user derived from entry.Chown; scheduler-k3s creates a throwaway Pod via the kubernetes API, waits for it to reach Running with structured error reporting (ImagePullBackOff and friends are surfaced from the container status verbatim, no kubectl involvement), execs the user command via the existing SPDY plumbing in k8s.go, and deletes the Pod on the way out. (Entry).Validate now accepts either an absolute path or a docker named-volume token for docker-local entries so the migration synthesizer's named-volume legacy entries work cleanly. storage:exec gains --as-user for one-off uid overrides, propagates the underlying tool's exit code via os.Exit, and detects TTY/interactive mode from os.Stdin so non-interactive scripted use no longer trips over docker's input-device-is-not-a-tty error.
2026-04-29 23:29:30 -04:00
Jose Diaz-Gonzalez
2758b3cc47 chore: rename trigger function 2025-06-10 23:36:10 -04:00
Jose Diaz-Gonzalez
b663f71878 feat: only write cron entries when working on docker-local scheduler 2025-06-10 21:45:08 -04:00
Jose Diaz-Gonzalez
398a78b2f6 refactor: move cron-write to scheduler-cron-write 2025-06-10 21:45:08 -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