DVA-C02 Question 298
Select 3You are tasked with setting up a CI/CD pipeline for a serverless application that uses AWS Lambda, Amazon API Gateway, and Amazon DynamoDB. The pipeline should automatically build, test, and deploy the code when changes are committed to a GitHub repository. Which combination of AWS services and features should you use to achieve this?
- A
AWS CodePipeline for orchestrating the CI/CD workflow
- B
AWS CodeBuild for building and testing the application
- C
AWS Elastic Beanstalk for deploying the serverless application
- D
AWS CodeDeploy with the Lambda deployment configuration for deploying updates to the Lambda function
- E
Amazon S3 for hosting the Lambda function code
Show answer and explanation
Correct answers: A, B, D
Explanation
To create a CI/CD pipeline for a serverless application, AWS CodePipeline can be used to orchestrate the workflow, AWS CodeBuild to handle building and testing, and AWS CodeDeploy with the Lambda deployment configuration to manage the deployment of updates to Lambda functions. AWS Elastic Beanstalk and Amazon S3 are not suitable for this specific use case.
- A. Correct.
Correct: AWS CodePipeline is a fully managed service that automates CI/CD workflows, making it an appropriate choice for orchestrating the CI/CD process.
- B. Correct.
Correct: AWS CodeBuild compiles the source code, runs tests, and produces build artifacts, which is essential for any CI/CD pipeline.
- C. Incorrect.
Incorrect: AWS Elastic Beanstalk is used for deploying web applications, not serverless applications like AWS Lambda.
- D. Correct.
Correct: AWS CodeDeploy with the Lambda deployment configuration is specifically designed for deploying updates to AWS Lambda functions in a controlled and automated manner.
- E. Incorrect.
Incorrect: Amazon S3 is used for storing static files or artifacts, not for hosting or deploying serverless application code directly.