We have longish builds that typically we schedule our cron jobs around, but on occasion we have to re-run a build during a non-standard timeframe and can run into conflicts with cron jobs that are typically safe to run at those times.
We have multiple accounts that run both builds and cron jobs, so we can't suspend the crontab service for the entire machine and then restart it later.
I was wondering if anyone had a pattern or implementation. I imagine this working like
User creates a file: ~/block-crontab
user runs build
The cron job looks for that file in the home dir of the user and if it's there is just skips all cron jobs.
Otherwise it runs the jobs
Then when build is done, user removes ~/block-crontab
Would that work? I'm guessing I'd need to modify the cron script somehow. I'm mostly wondering if there is a better/standard approach to this issue?
thanks.