HorizontalRunnerAutoscaler
actions.summerwind.dev / v1alpha1
apiVersion: actions.summerwind.dev/v1alpha1
kind: HorizontalRunnerAutoscaler
metadata:
name: example
apiVersion
string
APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
kind
string
Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
metadata
object
spec object
HorizontalRunnerAutoscalerSpec defines the desired state of HorizontalRunnerAutoscaler
capacityReservations []object
effectiveTime
string
format:
date-time
expirationTime
string
format:
date-time
name
string
replicas
integer
githubAPICredentialsFrom object
secretRef object
name
string required
maxReplicas
integer
MaxReplicas is the maximum number of replicas the deployment is allowed to scale
metrics []object
Metrics is the collection of various metric targets to calculate desired number of runners
repositoryNames
[]string
RepositoryNames is the list of repository names to be used for calculating the metric. For example, a repository name is the REPO part of `github.com/USER/REPO`.
scaleDownAdjustment
integer
ScaleDownAdjustment is the number of runners removed on scale-down. You can only specify either ScaleDownFactor or ScaleDownAdjustment.
scaleDownFactor
string
ScaleDownFactor is the multiplicative factor applied to the current number of runners used to determine how many pods should be removed.
scaleDownThreshold
string
ScaleDownThreshold is the percentage of busy runners less than which will trigger the hpa to scale the runners down.
scaleUpAdjustment
integer
ScaleUpAdjustment is the number of runners added on scale-up. You can only specify either ScaleUpFactor or ScaleUpAdjustment.
scaleUpFactor
string
ScaleUpFactor is the multiplicative factor applied to the current number of runners used to determine how many pods should be added.
scaleUpThreshold
string
ScaleUpThreshold is the percentage of busy runners greater than which will trigger the hpa to scale runners up.
type
string
Type is the type of metric to be used for autoscaling. It can be TotalNumberOfQueuedAndInProgressWorkflowRuns or PercentageRunnersBusy.
minReplicas
integer
MinReplicas is the minimum number of replicas the deployment is allowed to scale
scaleDownDelaySecondsAfterScaleOut
integer
ScaleDownDelaySecondsAfterScaleUp is the approximate delay for a scale down followed by a scale up Used to prevent flapping (down->up->down->... loop)
scaleTargetRef object
ScaleTargetRef is the reference to scaled resource like RunnerDeployment
kind
string
Kind is the type of resource being referenced
enum:
RunnerDeployment, RunnerSet
name
string
Name is the name of resource being referenced
scaleUpTriggers []object
ScaleUpTriggers is an experimental feature to increase the desired replicas by 1 on each webhook requested received by the webhookBasedAutoscaler.
This feature requires you to also enable and deploy the webhookBasedAutoscaler onto your cluster.
Note that the added runners remain until the next sync period at least, and they may or may not be used by GitHub Actions depending on the timing. They are intended to be used to gain "resource slack" immediately after you receive a webhook from GitHub, so that you can loosely expect MinReplicas runners to be always available.
amount
integer
duration
string
githubEvent object
checkRun object
https://docs.github.com/en/actions/reference/events-that-trigger-workflows#check_run
names
[]string
Names is a list of GitHub Actions glob patterns. Any check_run event whose name matches one of patterns in the list can trigger autoscaling. Note that check_run name seem to equal to the job name you've defined in your actions workflow yaml file. So it is very likely that you can utilize this to trigger depending on the job.
repositories
[]string
Repositories is a list of GitHub repositories. Any check_run event whose repository matches one of repositories in the list can trigger autoscaling.
status
string
types
[]string
One of: created, rerequested, or completed
pullRequest object
https://docs.github.com/en/actions/reference/events-that-trigger-workflows#pull_request
branches
[]string
types
[]string
push
object
PushSpec is the condition for triggering scale-up on push event Also see https://docs.github.com/en/actions/reference/events-that-trigger-workflows#push
workflowJob
object
https://docs.github.com/en/developers/webhooks-and-events/webhooks/webhook-events-and-payloads#workflow_job
scheduledOverrides []object
ScheduledOverrides is the list of ScheduledOverride. It can be used to override a few fields of HorizontalRunnerAutoscalerSpec on schedule. The earlier a scheduled override is, the higher it is prioritized.
endTime
string required
EndTime is the time at which the first override ends.
format:
date-time
minReplicas
integer
MinReplicas is the number of runners while overriding. If omitted, it doesn't override minReplicas.
minimum:
0recurrenceRule object
frequency
string
Frequency is the name of a predefined interval of each recurrence. The valid values are "Daily", "Weekly", "Monthly", and "Yearly". If empty, the corresponding override happens only once.
enum:
Daily, Weekly, Monthly, Yearly
untilTime
string
UntilTime is the time of the final recurrence. If empty, the schedule recurs forever.
format:
date-time
startTime
string required
StartTime is the time at which the first override starts.
format:
date-timestatus object
cacheEntries []object
expirationTime
string
format:
date-time
key
string
value
integer
desiredReplicas
integer
DesiredReplicas is the total number of desired, non-terminated and latest pods to be set for the primary RunnerSet This doesn't include outdated pods while upgrading the deployment and replacing the runnerset.
lastSuccessfulScaleOutTime
string
format:
date-time
observedGeneration
integer
ObservedGeneration is the most recent generation observed for the target. It corresponds to e.g. RunnerDeployment's generation, which is updated on mutation by the API Server.
format:
int64
scheduledOverridesSummary
string
ScheduledOverridesSummary is the summary of active and upcoming scheduled overrides to be shown in e.g. a column of a `kubectl get hra` output for observability.
No matches. Try .spec.capacityReservations for an exact path