Create the us-east-1 artifact store bucket for CodePipeline and add a deploy action using the us-east-1 template artifact

Answer Correct answer: C, E — create the us-east-1 artifact store bucket for CodePipeline and add a deploy action using the us-east-1 artifact.

A company has an AWS CodePipeline pipeline in the eu-west-1 Region. The pipeline stores the build artifacts in an Amazon S3 bucket. The pipeline builds and deploys an AWS Lambda function by using an AWS CloudFormation deploy action. A DevOps engineer needs to update the existing pipeline to also deploy the Lambda function to the us-east-1 Region. The pipeline has already been updated to create an additional artifact to deploy to us-east-1. Which combination of steps should the DevOps engineer take to meet these requirements? (Choose two.)

  1. Modify the CloudFormation template to include a parameter for the Lambda function code's .zip file location. Create a new CloudFormation deploy action for us-east-1 in the pipeline. Configure the new deploy action to pass in the us-east-1 artifact location as a parameter override.
  2. Create a new CloudFormation deploy action for us-east-1 in the pipeline. Configure the new deploy action to use the CloudFormation template from the additional artifact that was created for us-east-1.
  3. Create an S3 bucket in us-east-1. Configure the S3 bucket policy to allow CodePipeline to have read and write access. Correct Answer
  4. Create an S3 bucket in us-east-1. Configure S3 Cross-Region Replication (CRR) from the S3 bucket in eu-west-1 to the S3 bucket in us-east-1.
  5. Modify the pipeline to include the S3 bucket for us-east-1 as an artifact store. Create a new CloudFormation deploy action for us-east-1 in the pipeline. Configure the new deploy action to use the CloudFormation template from the us-east-1 artifact. Correct Answer

Community Votes

CE
100%

100% of anonymous learners picked answer CE. Votes are pick records left by other test-takers — they are not the verified answer.

Community Insight

A CloudFormation deploy action resolves its template from the pipeline's artifacts, so pointing a new us-east-1 deploy action at the us-east-1 artifact selects the Region-appropriate template (E). That artifact has to live somewhere, which requires an S3 bucket in us-east-1 whose bucket policy grants CodePipeline read and write access, since CodePipeline accesses the artifact store directly with its service role rather than through the pipeline's own credentials (C). Parameterizing the Lambda code location and overriding a parameter (A) does not address where the cross-Region template comes from, and option D's cross-Region replication duplicates build output the pipeline already produces per Region.

The pipeline already produces an additional artifact for us-east-1, so the Region-specific work is the artifact store and the deploy action. Creating an Amazon S3 bucket in us-east-1 and granting CodePipeline read and write access to it provides the artifact store the pipeline needs in that Region. Adding that bucket to the pipeline as an artifact store and creating a CloudFormation deploy action for us-east-1 that uses the CloudFormation template from the us-east-1 artifact then deploys the Lambda function there.

Parameterizing the template for the Lambda .zip location and adding a deploy action with a parameter override (A) — eugene2owl identified that merely overriding a code-location parameter is not enough, because the us-east-1 action needs its own CloudFormation template artifact rather than a passed-in code path, and no Region-local artifact store is provided. Using S3 Cross-Region Replication from the eu-west-1 bucket to a new us-east-1 bucket (D) — replication copies build output, but the pipeline already creates a Region-specific artifact and cross-Region replication adds latency and cost without supplying the template artifact the deploy action consumes. Selecting only E omits the bucket creation and access policy that the artifact store requires.

Community Discussion (5 comments)

Srikantha 👍 1 Selected: CE
Question says pipeline already modified to create the artifact in us-east-1
asimohat 👍 1 Selected: BC
The question states “The pipeline has already been updated to create additional deliverables to deploy to us-east-1. Option B simply adds a deploy action in a way that leverages this existing update.
tubtab 👍 2 Selected: CE
Correct
eugene2owl 👍 3 Selected: CE
Correct ansers "C" and "E". "A" is wrong for sure, because it's not enough to simply bypass a new Lambda code location as a parameter of existing CloudFormation Template: you need NOT only another Lambda code location, but also another region, another VPC id, etc. So you need to have a second dedicated separate template.
gunjan229 👍 2 Selected: CE
Correct Answer C, E

Comments & Corrections

No comments yet — spotted an error or have a note? Share it below.

Log in to comment, report an error, or add a note about this question.

Submitted for moderation before publishing. Keep it helpful and respectful.

Expert Analysis

Why the Answer Is Correct

The pipeline has already been updated to produce an additional artifact for us-east-1, so two things remain. First, the pipeline needs an artifact store in that Region: creating an S3 bucket in us-east-1 and configuring its bucket policy to allow CodePipeline read and write access gives the pipeline somewhere to place and retrieve the us-east-1 artifact, which CodePipeline accesses with its service role (C). Second, adding that bucket to the pipeline as an artifact store and creating a new CloudFormation deploy action for us-east-1 configured to use the CloudFormation template from the us-east-1 artifact makes the deploy action resolve the correct Region-appropriate template and deploy the Lambda function there (E). C and E together complete the multi-Region deployment with no custom code.

Why the Other Options Are Wrong

A modifies the CloudFormation template to accept the Lambda.zip location as a parameter and adds a deploy action passing that location as a parameter override. As eugene2owl explained, this is not sufficient: the cross-Region CloudFormation action still needs a template appropriate for that Region, and substituting a code location parameter does not address where the template itself comes from, nor does it create the Region-local artifact store the pipeline requires. B creates a us-east-1 deploy action using the template from the additional artifact, which addresses only the template source and leaves the pipeline without an artifact store in us-east-1, so the artifact the action consumes has nowhere to live. D replicates the eu-west-1 build bucket into us-east-1, which copies build output that the pipeline already produces per Region, introduces replication lag, and does not create the Region-specific template artifact or a pipeline artifact store. Selecting E alone omits the bucket and its CodePipeline access policy, which is the C requirement. C and E are the correct combination.

Community Comment Notes

Community voted C,E (89), with only two votes elsewhere. Commenters noted the question already states the pipeline was updated to create the additional artifact, so what remains is the Region-local artifact store bucket and the deploy action that consumes it. eugene2owl specifically ruled out A on the grounds that a parameter override is not a substitute for a Region-appropriate template artifact. asimohat favored B alone, which supplies the template source but omits the artifact store bucket entirely.

Official Reference

Related Analysis

Practice All DOP-C02 Questions

Access 85 questions with complete answers and detailed explanations.

View Full DOP-C02 Practice Test →

← Back to DOP-C02 Study Guide