| « PreviousNext » | |
![]() ![]() ![]() | Did this page help you? Yes | No | Tell us about it... |
You can set up Auto Scaling to launch a certain number of instances at a specific time. This capability is useful if, for example, you want to take advantage of a window of time when prices historically are lower, or you want to terminate Spot Instances at a specific time.
We will use the Auto Scaling CLI command as-put-scheduled-update-group-action to set up a schedule. This is the basic syntax:
as-put-scheduled-update-group-action
ScheduledActionName --auto-scaling-group value [--desired-capacity value]
[--end-time value][--max-size value][--min-size value]
[--recurrence value][--start-time value][--time value][General Options]
In this scenario, use the following values:
Scheduled action name: as-spotbid-schedule
Auto Scaling group: spotasg
Start time: 2012-05-15T19:10:00Z
End time: 2012-05-15T19:15:00Z
Desired capacity:20
Your command should look similar to the following example:
as-put-scheduled-update-group-action as-spotbid-schedule --auto-scaling-group spotasg --desired-capacity 20 --start-time 2012-05-15T19:10:00Z --end-time 2012-05-15T19:15:00Z
You should get a confirmation like the following example:
OK-Put Scheduled Update Group Action
To check your scheduled action, run as-describe-scheduled-actions.
You will get information similar to the following example:
UPDATE-GROUP-ACTION spotasg as-spotbid-schedule 2012-05-15T19:10:00Z 20
What do you want to do next?