CLF-C02
Deep Dive
AWS offers multiple ways to interact with its services and deploy infrastructure. The CLF-C02 tests when to use the web console vs CLI vs SDK, the benefits of Infrastructure as Code, and when to choose cloud, on-premises, or hybrid.
Contents
Every operation on AWS is an HTTP API call. The different access methods are simply different ways of making those API calls.
AWS Management Console
Web GUIGraphical web interface for managing every AWS service. The main entry point for users who prefer a visual interface. Accessible from any browser at console.aws.amazon.com.
When to use
Exploring services, one-off tasks, complex configurations with many visual options, debugging, non-technical users.
Limitations
Repetitive operations across many resources. Higher risk of human error.
AWS CLI (Command Line Interface)
Terminal / ScriptsUnified command-line tool for managing every AWS service. Enables scripting and automation. Available on Windows, macOS, and Linux.
When to use
Automation scripts, bulk resource management, CI/CD pipeline integration, technical users who prefer the terminal.
Limitations
Not ideal for initial service exploration or for users without terminal experience.
AWS SDKs
Code integrationLibraries for interacting with AWS from application code. Available for Python (boto3), JavaScript/Node.js, Java, .NET, Go, Ruby, PHP, and more.
When to use
Applications that need to interact with AWS programmatically (e.g., an app that uploads files to S3, a Lambda that reads from DynamoDB).
Limitations
Not for infrastructure administration — use CLI or CloudFormation for that.
Direct REST APIs
Direct HTTPEvery AWS operation is an HTTP API (GET, POST, PUT, DELETE). The SDKs and CLI are convenient wrappers around these APIs. You can call them directly with any HTTP client.
When to use
Advanced cases: languages without an official SDK, integration with tools that only support HTTP.
Limitations
In practice you should always use the SDK or CLI instead of calling the REST API directly.
AWS CloudShell
Browser-based terminalBrowser-based terminal with the AWS CLI preinstalled, directly inside the AWS console. Nothing to install locally. Secure access using the credentials of the current session.
When to use
Running CLI commands without installing anything. Handy for quick tasks from any machine. Great for demos and learning.
Limitations
Not for long-running scripts (limited session). Files do not persist between sessions (except the home directory).
Infrastructure as Code (IaC) is the practice of defining and managing infrastructure through code instead of manual processes. It lets you treat infrastructure like any other code: version-controlled, reviewed, tested, and automated.
AWS CloudFormation
Declarative IaC using JSON/YAML templates
Define your AWS infrastructure in template files (JSON or YAML). CloudFormation provisions and configures every resource automatically in the correct order.
AWS CDK (Cloud Development Kit)
Framework for defining IaC using real programming languages: Python, TypeScript, Java, .NET. The CDK generates CloudFormation templates automatically. More productive for developers who prefer real code over YAML.
Elastic Beanstalk as a PaaS alternative
Elastic Beanstalk is a higher-level alternative: you upload your code (ZIP, WAR, JAR) and AWS automatically provisions EC2, ELB, Auto Scaling, and more. No IaC templates to write. Ideal for teams that just want to deploy code.
Benefits of IaC
Repeatability
The same template creates identical environments in dev, staging, and prod. No configuration drift.
Version control
Infrastructure lives in Git. Full change history, code review, branches.
Consistency
Eliminates manual errors. The exact same infrastructure every time, no "works on my machine."
Automation
CI/CD can deploy infrastructure and applications automatically. Faster delivery cycles.
The exam can present scenarios where you must pick the right deployment model based on business requirements.
☁️
Cloud (Public cloud)
All resources run on AWS infrastructure. No owned hardware. Fully managed.
Advantages
When to choose
New applications, startups, variable workloads, small teams without infrastructure expertise.
🏢
On-premises (Private cloud)
Infrastructure owned in the company's own datacenter. AWS Outposts can bring AWS hardware into that datacenter.
Advantages
When to choose
Highly sensitive data, regulations that prohibit the cloud, latency requirements <1ms, disconnected environments.
🔀
Hybrid
A combination of cloud and on-premises connected via VPN or AWS Direct Connect. The best of both worlds.
Advantages
When to choose
Companies transitioning to the cloud, regulated data that cannot leave the country, extending on-prem capacity.
Connectivity for the hybrid model
AWS VPN (Site-to-Site): encrypted connection over the public internet between your datacenter and AWS. Quick to set up, lower cost, variable latency.
AWS Direct Connect: dedicated private connection between your datacenter and AWS. Higher bandwidth, consistent latency, no public internet. More expensive and slower to set up.
Manual processes (one-time)
For tasks done once or exceptionally, the web console or interactive CLI are appropriate.
Tools: Web console, interactive AWS CLI, CloudShell
Automated processes (repeatable)
For repetitive, consistent, scalable tasks, automation is essential. It reduces errors and frees up the team's time.
Tools: CloudFormation, CDK, Systems Manager, EventBridge Rules
CI/CD with AWS CodePipeline
AWS CodePipeline automates the full delivery flow: from code commit to production deployment. It integrates CodeBuild (build/test), CodeDeploy (deployment), and more.
AWS Outposts brings AWS infrastructure, services, APIs, and tools to virtually any customer facility. It's physical AWS hardware installed in your datacenter, managed remotely by AWS.
Key features
When to use Outposts
For the exam
AWS Outposts = a hybrid model where AWS manages the on-premises hardware. Same experience as AWS, but in your datacenter.
Did you get this topic?
Test what you just learned
A company wants to deploy identical environments for development, staging, and production on AWS. Each environment is currently created manually in the console, which leads to configuration drift between environments. Which approach best solves this problem?
Put what you learned to the test with original CLF-C02 exam questions.
Start CLF-C02 mock examUnlimited mock exams with the Pro plan
Log in to track your progress.