Pular para o conteúdo
#0036
CronContainers

A crontab per branch, deployed with the code

Your repo has a crontab.json checked in. When you deploy a branch: main, staging, feature/billing-rewrite: the deploy script POSTs that file to the new container's hoody-cron API. Each branch gets its container, its filesystem, its crontab.

The feature branch with the experimental hourly job doesn't touch staging. Staging's scheduler doesn't touch prod. When you delete the branch, you tear down the container, and the schedules go with it. There's no shared "staging cron server" to clean up, no if BRANCH_ENV == 'staging' guards inside the jobs themselves.

Your schedule used to be a thing the ops team configured in one place. It's now a thing your branch carries with it.

The schedule lives next to the code that runs on it, in the same container, on the same branch.