Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix RunerSet managed runner pods to terminate more gracefully #1126

Merged
merged 1 commit into from
Feb 19, 2022

Conversation

mumoshu
Copy link
Collaborator

@mumoshu mumoshu commented Feb 17, 2022

Make RunnerSet-managed runners as reliable as RunnerDeployment-managed runners.

Ref #911 (comment)

// - (false, nil) when the runner has been already unregistered.
// - (false, err) when it postponed unregistration due to the runner being busy, or it tried to unregister the runner but failed due to
// an error returned by GitHub API.
func unregisterRunner(ctx context.Context, client *github.Client, enterprise, org, repo, name string) (bool, error) {
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This function is derived from RunnerReconciler's unregisterRunner function which was problem-free.

We now use this from the runner controller (a counter-part of RunnerDeployment controller) and the runner pod controller (which is a counter-part of RunnerSet controller) to make runnsetset-managed runners as reliable as runnerdeployment's.

@mumoshu mumoshu merged commit a5ed6bd into master Feb 19, 2022
@mumoshu mumoshu deleted the fix-runnerset-runner-terminate-more-gracefully branch February 19, 2022 12:19
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.

None yet

1 participant