AWS Certified SysOps Administrator – Associate (legacy) — Question 892
A custom application must be installed on all Amazon EC2 instances. The application is small, updated frequently and can be installed automatically.
How can the application be deployed on new EC2 instances?
Answer options
- A. Launch a script that downloads and installs the application using the Amazon EC2 user data.
- B. Create a custom API using Amazon API Gateway to call an installation executable from an AWS CloudFormation Template.
- C. Use AWS Systems Manager to inject the application into an AMI.
- D. Configure AWS CodePipeline to deploy code changes and updates.
Correct answer: A
Explanation
Since the application is small and updated frequently, using Amazon EC2 user data to run an installation script during instance boot is the ideal approach as it avoids the overhead of constantly rebuilding AMIs. Baking the application into an AMI via AWS Systems Manager would be too slow and tedious for frequent updates, while using Amazon API Gateway adds unnecessary complexity. AWS CodePipeline is a CI/CD tool and does not inherently handle the initial bootstrapping of new EC2 instances.