actions-runner-controller/controllers
Yusuke Kuoka eca6917c6a feat: Organizational RunnerDeployment Autoscaling
Enhances #57 to add support for organizational runners.

As GitHub Actions does not have an appropriate API for this, this is the spec you need:

```
apiVersion: actions.summerwind.dev/v1alpha1
kind: RunnerDeployment
metadata:
  name: myrunners
spec:
  minReplicas: 1
  maxReplicas: 3
  autoscaling:
    metrics:
    - type: TotalNumberOfQueuedAndProgressingWorkflowRuns
      repositories:
      # Assumes that you have `github.com/myorg/myrepo1` repo
      - myrepo1
      - myrepo2
  template:
    spec:
      organization: myorg
```

It works by collecting "in_progress" and "queued" workflow runs for the repositories `myrepo1` and `myrepo2` to autoscale the number of replicas, assuming you have this organizational runner deployment only for those two repositories.

For example, if `myrepo1` had 1 `in_progress` and 2 `queued` workflow runs, and `myrepo2` had 4 `in_progress` and 8 `queued` workflow runs at the time of running the reconcilation loop on the runner deployment, it will scale replicas to 1 + 2 + 4 + 8 = 15.

Perhaps we might be better add a kind of "ratio" setting so that you can configure the controller to create e.g. 2x runners than demanded. But that's another story.

Ref #10
2020-07-03 09:12:47 +09:00
..
autoscaling.go feat: Organizational RunnerDeployment Autoscaling 2020-07-03 09:12:47 +09:00
autoscaling_test.go feat: Organizational RunnerDeployment Autoscaling 2020-07-03 09:12:47 +09:00
runner_controller.go Merge pull request #50 from summerwind/runner-validation-webhook 2020-05-08 22:39:13 +09:00
runnerdeployment_controller.go feat: Organizational RunnerDeployment Autoscaling 2020-07-03 09:12:47 +09:00
runnerdeployment_controller_test.go Revert test comment 2020-03-15 21:55:38 +09:00
runnerreplicaset_controller.go Add permission to create/patch events resource 2020-03-27 23:25:37 +09:00
runnerreplicaset_controller_test.go Revert test comment 2020-03-15 21:55:38 +09:00
suite_test.go Initial commit 2020-01-28 15:03:23 +09:00