Gitlab CI Config: how to skip/fail a job if a runner is not available

How to skip/fail a job if a specific runner is not available

I’ve installed an own runner on an old Macbook which is only responsible to run jobs to build a MacOS app. (I use the tags keyword the select to correct runner.)

The problem: it is somehow unreliable that the Macbook is available and it is also turned off sometimes. If the runner is not available, this blocks the whole (much bigger) pipeline because of a pending job.

How can I skip and fail the job, if the respective runner is not available? Maybe even after a timeout, e.g. if the runner is not available since 10 minutes.

I’ve tried the timeout keyword but this seems only to apply if the job already started. Is there something else that I’ve missed?

Thanks in advance