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

Scaling from/to 0 capabilities #1618

Open
dcardellino opened this issue Apr 11, 2023 · 3 comments
Open

Scaling from/to 0 capabilities #1618

dcardellino opened this issue Apr 11, 2023 · 3 comments
Labels
customer-request kind/feature Categorizes issue or PR as related to a new feature. sig/cluster-management Denotes a PR or issue as being assigned to SIG Cluster Management.

Comments

@dcardellino
Copy link

Cluster Autoscaler added support for "Scaling from/to 0". Talking with @xmudrii I open this issue to verify if this is feasible.

https://github.com/kubernetes/autoscaler/tree/master/cluster-autoscaler/cloudprovider/clusterapi#scale-from-zero-support

@xmudrii xmudrii added sig/cluster-management Denotes a PR or issue as being assigned to SIG Cluster Management. kind/feature Categorizes issue or PR as related to a new feature. labels Apr 11, 2023
@acbox
Copy link

acbox commented May 10, 2023

This would be a great feature to reduce the cost of cloud development environments, by scaling down to 0 outside of business hours.

@Skarlso
Copy link

Skarlso commented Mar 1, 2024

As far as I understand it, isn't it just that we need to add Capacity in the machine status:

        // Capacity defines the resource capacity for this machine.
	// This value is used for autoscaling from zero operations as defined in:
	// https://github.com/kubernetes-sigs/cluster-api/blob/main/docs/proposals/20210310-opt-in-autoscaling-from-zero.md
	// +optional
	Capacity corev1.ResourceList `json:"capacity,omitempty"`

And the rest can be taken care of by the cluster autoscaler once certain annotations are provided.

@Skarlso
Copy link

Skarlso commented Mar 1, 2024

Here is an example on how to apply and use it with CAPA which is using CAPI: kubernetes-sigs/cluster-api-provider-aws#3684

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
customer-request kind/feature Categorizes issue or PR as related to a new feature. sig/cluster-management Denotes a PR or issue as being assigned to SIG Cluster Management.
Projects
None yet
Development

No branches or pull requests

5 participants