Skip to content

Add randomized suffix to runner names#183

Merged
theihor merged 1 commit into
mainfrom
runner-not-found
May 13, 2025
Merged

Add randomized suffix to runner names#183
theihor merged 1 commit into
mainfrom
runner-not-found

Conversation

@theihor

@theihor theihor commented May 13, 2025

Copy link
Copy Markdown
Contributor

BPF CI runners went down recently due to a problem caused by "Runner not found" error returned from a github broker service [1].

It appears that this error may be triggered by the fact that runner names are reused for "different" runners from the perspective of github. In BPF CI we use ephemeral runners which re-register every time a corresponding runner container is restarted.

Whatever the root cause, a working mitigation is to use unique runner names. Fortunately, entrypoint.sh [1] already has the logic of generating a random suffix, and we only need to set relevant environment variables.

Additionally, set RestartPreventExitStatus=199 in the runner systemd service to prevent error looping in case we run out of tokens [2].

[1] https://github.com/myoung34/docker-github-actions-runner/blob/2.323.0/entrypoint.sh
[2] kernel-patches/runner#75

BPF CI runners went down recently due to a problem caused by "Runner
not found" error returned from a github broker service [1].

It appears that this error may be triggered by the fact that runner
names are reused for "different" runners from the perspective of
github. In BPF CI we use ephemeral runners which re-register every
time a corresponding runner container is restarted.

Whatever the root cause, a working mitigation is to use unique runner
names. Fortunately, entrypoint.sh [1] already has the logic of
generating a random suffix, and we only need to set relevant
environment variables.

Additionally, set RestartPreventExitStatus=199 in the runner systemd
service to prevent error looping in case we run out of tokens [2].

[1] https://github.com/myoung34/docker-github-actions-runner/blob/2.323.0/entrypoint.sh
[2] kernel-patches/runner#75

Signed-off-by: Ihor Solodrai <isolodrai@meta.com>
@theihor theihor merged commit 151eda0 into main May 13, 2025
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant