Skip to content

ScheduledAction

Source: src/AWS/AutoScaling/ScheduledAction.ts

A scheduled scaling action that changes an Auto Scaling Group’s capacity on a recurring cron schedule or at a single future time.

Scale up every weekday morning

const action = yield* ScheduledAction("MorningScaleUp", {
autoScalingGroup: group,
recurrence: "0 9 * * MON-FRI",
timeZone: "America/New_York",
minSize: 2,
maxSize: 10,
desiredCapacity: 4,
});

One-time capacity change

const action = yield* ScheduledAction("BlackFriday", {
autoScalingGroup: group,
startTime: "2026-11-27T00:00:00Z",
desiredCapacity: 20,
});