
Ask HN: Simple tool to schedule cloud resource scale up/down? - kierenj
I&#x27;m looking for something which can allow setup&#x2F;automation of cloud resource scaling schedules or rules.  Ideally, it&#x27;d be cross-provider and allow something like:<p>- At 6am, if service tier of resource X is less than Y, increase it to Y<p>- From 8am-1pm, unless usage % of resource X is greater than 25%, decrease service tier to Z<p>- Override rule 2 if it&#x27;s the weekend..<p>I guess, some system for evaluating and executing scaling rules, based on some criteria, scheduling, and priority.<p>I&#x27;ve done some digging and can&#x27;t find such a thing.  It&#x27;s obviously possible with scripts and jobs, but I&#x27;d like the advantages of some kind of web UI.  Anyone using (or built) anything like this?
======
tedmiston
[I'm assuming you're not managing nodes using a container orchestration tool
like Kubernetes.]

Have you looked at something like Auto Scaling Groups (AWS) / Autoscaling
Groups (GCP)?

You can customize the auto-scaling policy for how the nodes scale up / down.
You can define the auto-scaling policies around load balancing at some level
(e.g., CPU utilization, HTTP load balancing, network load balancing) which is
discussed in more detail in the docs below [1].

You can also create arbitrary metrics and arbitrary policies for those metrics
and scale with a combination of policies. From [2]:

> The autoscaler handles multiple policies by calculating the recommended
> number of virtual machines for each policy and then picking the policy that
> leaves the largest number of virtual machines in the group.

Usually auto-scaling config is tied to a particular service provider; while I
haven't done cloud-agnostic auto-scaling policies before personally, I would
guess it could be achieved with a bit more effort using something like
Terraform (examples: AWS [3], GCP [4]).

[1]: [https://cloud.google.com/compute/docs/load-balancing-and-
aut...](https://cloud.google.com/compute/docs/load-balancing-and-autoscaling)

[2]: [https://cloud.google.com/compute/docs/autoscaler/multiple-
po...](https://cloud.google.com/compute/docs/autoscaler/multiple-policies)

[3]:
[https://www.terraform.io/docs/providers/aws/r/autoscaling_po...](https://www.terraform.io/docs/providers/aws/r/autoscaling_policy.html)

[4]:
[https://www.terraform.io/docs/providers/google/r/compute_aut...](https://www.terraform.io/docs/providers/google/r/compute_autoscaler.html)

------
darkr
Not cross provider obviously, but EC2 autoscaling has supported this for
years:
[https://docs.aws.amazon.com/autoscaling/ec2/userguide/schedu...](https://docs.aws.amazon.com/autoscaling/ec2/userguide/schedule_time.html)

------
WAthrowaway
>I'm looking for something which can allow setup/automation of cloud resource
scaling schedules or rules.

Terraform + chron/some timing script

>but I'd like the advantages of some kind of web UI

Set up a Jenkins instance on $CLOUD_PROVIDER_OF_YOUR_CHOICE (~20 min) to run
Terraform on a specified schedule

