Skip to content

EphemeralRunner: On cleanup, if pod is pending, delete from service#2255

Merged
TingluoHuang merged 8 commits into
masterfrom
nikola-jokic/manual-delete-issue-delete
Feb 12, 2023
Merged

EphemeralRunner: On cleanup, if pod is pending, delete from service#2255
TingluoHuang merged 8 commits into
masterfrom
nikola-jokic/manual-delete-issue-delete

Conversation

@nikola-jokic

Copy link
Copy Markdown
Collaborator

If pod is unable to start due to image pull issue, the pod will get stuck in Pending phase. It would require manual intervention to delete that ephemeral runner.

This change removes runner from the service if pod is pending (never actually started).

@nikola-jokic nikola-jokic requested review from a team, mumoshu and toast-gear as code owners February 6, 2023 15:14
@TingluoHuang

Copy link
Copy Markdown
Member

Will this cause ARC stuck in a loop of creating/deleting runners on the service?

@nikola-jokic

Copy link
Copy Markdown
Collaborator Author

Yes ☺️ . So basically, if the issue is on the container registry, the back-off will eventually pull it.
If the issue is some typo in the image field, you would need to update AutoscalingRunnerSet anyway.
The update will take care of deletion, but if someone manually tries to delete it (maybe by accident or image pull back-off tops at 5 minutes so to speed it up), then the runner will stay registered.

@TingluoHuang

Copy link
Copy Markdown
Member

@nikola-jokic The service will return 429 if you configure too many runners within a short time window.

Comment thread controllers/actions.github.com/ephemeralrunner_controller.go Outdated
@nikola-jokic nikola-jokic force-pushed the nikola-jokic/manual-delete-issue-delete branch from 1c007f4 to b664d11 Compare February 8, 2023 16:38
Comment thread controllers/actions.github.com/ephemeralrunner_controller.go Outdated
Comment thread controllers/actions.github.com/ephemeralrunner_controller.go Outdated
Comment thread controllers/actions.github.com/ephemeralrunner_controller.go Outdated
Comment thread controllers/actions.github.com/ephemeralrunner_controller.go Outdated
Comment thread controllers/actions.github.com/ephemeralrunner_controller.go
nikola-jokic and others added 4 commits February 11, 2023 18:01
@TingluoHuang TingluoHuang merged commit 8e52a6d into master Feb 12, 2023
@TingluoHuang TingluoHuang deleted the nikola-jokic/manual-delete-issue-delete branch February 12, 2023 00:55
unpollito pushed a commit to DistruApp/actions-runner-controller that referenced this pull request Jan 21, 2026
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.

2 participants