- Newest
- Most votes
- Most comments
This sounds like a use case for CloudWatch alarms with an appropriate trigger to execute EBS scaling operations. I haven't done this myself, but looking at the alarm actions docs (all linked below) it looks like worst-case I could use a lambda action to invoke a function that increases the size of the EBS volume and later extends the file system?
The EBS docs tell you modifications take time, and that you should monitor the operation. This is why in the blog post you provided they use use their lambda trigger to start executing step functions -- the step function allows them to request the volume change, monitor the request, and then continue with their file system extension after the EBS volume has finished resizing. An alternative would be to use SQS or EventBridge to kick off a Lambda function every few minutes to check the status until it completes.
Docs links:
- Alarm actions - https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/alarm-actions.html
- Triggering lambda functions - https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/alarms-and-actions-Lambda.html
- Modifying EBS volumes - https://docs.aws.amazon.com/ebs/latest/userguide/ebs-modify-volume.html
Relevant content
- asked 2 years ago
- AWS OFFICIALUpdated 3 years ago
- AWS OFFICIALUpdated 2 years ago
