ShaneMcC / AoCBench

Advent of Code Benchmarking
Other
7 stars 1 forks source link

Push-Based running rather than cron-based #6

Closed ShaneMcC closed 1 year ago

ShaneMcC commented 5 years ago

For next year it would be nice if we could accept webhooks or so that trigger runs rather than relying on a cronjob.

ShaneMcC commented 1 year ago

I do this now!

Calling the scheduledUpdate.php script in the web directory pokes a RabbitMQ instance.

Then checkScheduledUpdates.php can notice this and schedule the run and then checkRun.sh can be cronned every minute to pick up on this.

(In production I use a variation of checkScheduledUpdates.php that watches across all the various instances and touches the appropriate file, then I run all of the checkRun.sh scripts in turn)