0

I am new to AWS and want to create an auto scale policy in AWS that launch an instance based on output of an REST API.I am not able to find if this is possible and if so how?

aman_41907
  • 179
  • 10

1 Answers1

1

I don't think this is something you can achieve without writing a little code.

I suggest creating an AWS Lambda function to query the REST API and post some sort of numeric metric value to CloudWatch based on the response from the REST API. Schedule the Lambda function to run every 1 minute or 5 minutes depending on your need.

Then you will be able to configure the auto-scaling group to trigger off your custom metric.

Mark B
  • 183,023
  • 24
  • 297
  • 295
  • 3
    Alternatively, you could have the lambda directly change the desired capacity of the ASG (assuming you're using one and not talking about scaling something else) – Shahad Apr 10 '21 at 20:29