Courseiva
Cloud ConceptseasyMultiple ChoiceObjective-mapped

CLF-C02 Cloud Concepts Practice Question

Which statement best describes the concept of 'infrastructure as code' (IaC) in the context of AWS?

⚠ Common exam trap

It's easy for candidates to confuse IaC with configuration management (e.g., installing software on instances) or manual provisioning, leading candidates to pick options that describe operational tasks rather than the core IaC practice of defining infrastructure in version-controlled files.

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

Defining and provisioning cloud resources using version-controlled configuration files

Infrastructure as Code (IaC) is the practice of defining and managing cloud resources through machine-readable definition files (e.g., AWS CloudFormation templates or Terraform HCL) that are stored in version control. This allows for automated, repeatable, and consistent provisioning of AWS infrastructure, enabling change management, peer review, and rollback capabilities.

Answer analysis

Option-by-option breakdown

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

  • Using the AWS Management Console to provision resources manually

    Why it's wrong here

    Manually provisioning resources through the AWS Management Console is the antithesis of infrastructure as code: each action is a point-and-click operation that is not stored as an executable definition, cannot be peer-reviewed, and is not version-controlled. This approach creates configuration drift because there is no single source of truth, and it does not scale or reproduce environments consistently. IaC replaces this manual workflow with declarative templates that are applied through automation.

  • Writing scripts to install software on EC2 instances

    Why it's wrong here

    Writing scripts that install software or configure applications on EC2 instances is configuration management, not infrastructure as code. IaC focuses on provisioning the underlying cloud resources themselves—such as VPCs, subnets, EC2 instances, and security groups—using code, whereas scripts often run as user-data or via tools like Ansible after the infrastructure exists. While these scripts are code, they do not define or manage the infrastructure's lifecycle.

  • Defining and provisioning cloud resources using version-controlled configuration files

    Why this is correct

    Infrastructure as code is the practice of defining and provisioning cloud resources through version-controlled configuration files, such as AWS CloudFormation templates, AWS CDK applications, or Terraform configuration. These files describe the desired state of the infrastructure, are stored in Git for peer review and change tracking, and are applied through automated CI/CD pipelines to create, update, or delete resources consistently. This approach makes infrastructure reproducible, auditable, and recoverable, which is the core of IaC.

  • Backing up AWS resource configurations to Amazon S3

    Why it's wrong here

    Backing up AWS resource configurations to Amazon S3 merely snapshots the current state of resources—it does not provide a mechanism to recreate or manage them through code. Such backups might capture CloudFormation templates or AWS Config snapshots, but they are passive artifacts and cannot be executed to provision infrastructure. IaC, by contrast, is an active, code-driven process that defines desired state and manages the full lifecycle of resources, not just archives their configuration.

About these practice questions

This CLF-C02 question is part of Courseiva's 988-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This CLF-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 CLF-C02 exam.