DOP-C02 Question 77
Select 2Your organization uses a CI/CD pipeline to deploy a web application to AWS. The application requires an AMI to be created with pre-configured software packages. The pipeline must also ensure that the AMI creation process is automated, repeatable, and integrates seamlessly with the deployment of the application. Which combination of tools should you use to achieve this requirement?
- A
AWS CodeDeploy and EC2 Image Builder
- B
AWS CodePipeline and EC2 Image Builder
- C
AWS CodeBuild and EC2 Image Builder
- D
AWS CodeDeploy and Auto Scaling
- E
AWS CodePipeline and AWS CodeDeploy
Show answer and explanation
Correct answers: B, E
Explanation
To automate and orchestrate a CI/CD pipeline for an application that requires AMI creation, AWS CodePipeline is used to manage the overall pipeline. EC2 Image Builder is integrated into the pipeline to automate the creation of AMIs with pre-configured software. CodeDeploy can be used as the deployment mechanism to push the application to instances. Therefore, the correct combination is AWS CodePipeline with EC2 Image Builder (for AMI creation) and AWS CodePipeline with AWS CodeDeploy (for deployment).
- A. Incorrect.
AWS CodeDeploy and EC2 Image Builder are not directly integrated for orchestrating a CI/CD pipeline that includes AMI creation. EC2 Image Builder handles AMI creation, but CodeDeploy is more suited for deploying applications to compute instances, not orchestrating an entire pipeline.
- B. Correct.
AWS CodePipeline and EC2 Image Builder are a good combination. CodePipeline orchestrates the CI/CD pipeline, and EC2 Image Builder automates the creation of AMIs. This ensures the pipeline is automated and repeatable.
- C. Incorrect.
AWS CodeBuild and EC2 Image Builder are not sufficient together for a complete CI/CD pipeline. CodeBuild is primarily used for building and testing code, while EC2 Image Builder focuses on AMI creation. Orchestration of the pipeline is missing with just these two tools.
- D. Incorrect.
AWS CodeDeploy and Auto Scaling do not address AMI creation or pipeline orchestration. CodeDeploy is used for deploying applications, and Auto Scaling is used for scaling instances, but neither automates AMI creation or manages the CI/CD process.
- E. Correct.
AWS CodePipeline and AWS CodeDeploy work well together to orchestrate and deploy applications. CodePipeline manages the CI/CD process, and CodeDeploy handles the deployment stage. However, for AMI creation, you would integrate EC2 Image Builder into the pipeline.