nerdexam
AmazonAmazon

DOP-C02 · Question #198

DOP-C02 Question #198: Real Exam Question with Answer & Explanation

Sign in or unlock DOP-C02 to reveal the answer and full explanation for question #198. The question stem and answer options stay visible for context.

Submitted by suresh_in· Mar 6, 2026Configuration Management and Infrastructure as Code

Question

A DevOps engineer is setting up a container-based architecture. The engineer has decided to use AWS CloudFormation to automatically provision an Amazon ECS cluster and an Amazon EC2 Auto Scaling group to launch the EC2 container instances. After successfully creating the CloudFormation stack, the engineer noticed that, even though the ECS cluster and the EC2 instances were created successfully and the stack finished the creation, the EC2 instances were associating with a different cluster. How should the DevOps engineer update the CloudFormation template to resolve this issue?

Options

  • AReference the EC2 instances in the AWS::ECS::Cluster resource and reference the ECS cluster
  • BReference the ECS cluster in the AWS::AutoScaling::LaunchConfiguration resource of the
  • CReference the ECS cluster in the AWS::EC2::Instance resource of the UserData property.
  • DReference the ECS cluster in the AWS::CloudFormation::CustomResource resource to trigger an

Unlock DOP-C02 to see the answer

You've previewed enough free DOP-C02 questions. Unlock DOP-C02 for full answers, explanations, the timed quiz mode, progress tracking, and the master PDF. Question stem and options stay visible so you can still see what's on the exam.

Topics

#CloudFormation#ECS cluster#Auto Scaling Group#container instance registration
Full DOP-C02 PracticeBrowse All DOP-C02 Questions