Persistent self-hosted runners keep failing because a previous job left files and Docker images. Fix the root cause.
BeginnerScenarioRunners, ARC, Monorepos & Releases
Answer
Situation read → State leaking between jobs.
What I'd do →
- Move to ephemeral runners (
--ephemeralwith autoscaling, or ARC). - In the meantime, a job-completed hook (
ACTIONS_RUNNER_HOOK_JOB_COMPLETED=/opt/cleanup.sh) that wipes the workspace, prunes Docker and removes temp credentials.
Why → Cleanup scripts are a patch; ephemeral runners remove the class of problem.
Interview tip → Know the runner job-started and job-completed hooks.
More on Runners, ARC, Monorepos & Releases
You must build on runners that can reach an internal Artifactory. Design the runner setup.AdvancedDesign ARC for a company with Linux build jobs, Docker image builds, and GPU tests.AdvancedYou need to upgrade ARC across 10 clusters with zero dropped jobs. Plan it.AdvancedA monorepo has 30 services; every PR builds all of them. Redesign.AdvancedA monorepo deploys each service independently with its own version. How do you trigger and version releases?AdvancedDesign a release workflow for a CLI tool that publishes binaries for Linux, macOS and Windows.Intermediate