Courseiva
Question 1,586 of 418
Configuration Management and IaChardMultiple SelectObjective-mapped

DOP-C02 Configuration Management and IaC Practice Question

A DevOps engineer is designing an infrastructure as code solution for a microservices application that runs on Amazon ECS with Fargate. The application requires a shared Application Load Balancer (ALB) and multiple ECS services. Which CloudFormation resources are required to expose each service behind the ALB? (Choose THREE.)

⚠ Common exam trap

The trap here is that candidates often select the LoadBalancer resource (Option B) thinking it is required for each service, but the LoadBalancer is a shared resource created once, while the Listener, ListenerRules, and ECS Service are the per-service components that enable routing.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

AWS::ElasticLoadBalancingV2::Listener

AWS::ElasticLoadBalancingV2::Listener is correct because it defines the protocol and port (e.g., HTTP:80) on which the ALB accepts traffic. Without a listener, the ALB cannot receive incoming requests. This resource is essential for routing traffic to target groups that are associated with ECS services.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • AWS::ElasticLoadBalancingV2::Listener

    Why this is correct

    The listener receives incoming traffic on a specific port.

  • AWS::ElasticLoadBalancingV2::LoadBalancer

    Why it's wrong here

    The ALB is shared and created once, not per service.

  • AWS::ECS::Service

    Why this is correct

    The ECS service registers tasks with the target group.

  • AWS::ElasticLoadBalancingV2::ListenerRule

    Why this is correct

    Listener rules forward traffic to the appropriate target group.

  • AWS::AutoScaling::AutoScalingGroup

    Why it's wrong here

    Auto scaling groups are not used with Fargate; ECS manages scaling.

About these practice questions

Courseiva creates original exam-style practice questions with explanations and wrong-answer analysis. It does not publish real exam questions, exam dumps, or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

Last reviewed: Jun 24, 2026

Question Discussion

Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.

Loading comments…

Sign in to join the discussion.

This DOP-C02 practice question is part of Courseiva's free Amazon Web Services certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the DOP-C02 exam.