'Automate AWS SSM document execution
I have an AWS SSM document shared from another account, to install a software on an EC2 instance. Since there are auto-scaled EC2 instances, depending on the demand, new instances spin up.
Requirement is to automate this document execution on all the SSM Managed EC2 instances every day at a specified time, so that no EC2 instance will be left out without the required software.
What are the ways I can use here? I tried using the Run Command feature, but the name of document does not show up in the list.
Solution 1:[1]
- Write a Lambda function
- Fetch list of EC2 instances,
- use SSM (SendCommand) to run your document on each of the instances.
- Set up a Cloudwatch Event to invoke Lambda function daily at desired time.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Pankaj |
