mirror of
https://github.com/actions/actions-runner-controller.git
synced 2025-12-12 20:46:47 +00:00
feat: Organization RunnerDeployment with webhook-based autoscaling only for certain repositories (#766)
Resolves #765 Co-authored-by: Yusuke Kuoka <ykuoka@gmail.com>
This commit is contained in:
@@ -38,6 +38,16 @@ func (autoscaler *HorizontalRunnerAutoscalerGitHubWebhook) MatchCheckRunEvent(ev
|
||||
return false
|
||||
}
|
||||
|
||||
if len(scaleUpTrigger.GitHubEvent.CheckRun.Repositories) > 0 {
|
||||
for _, repository := range scaleUpTrigger.GitHubEvent.CheckRun.Repositories {
|
||||
if repository == *event.Repo.Name {
|
||||
return true
|
||||
}
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
return true
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user