Chapter 8 of 11
Module 8: Deployment, Operations, and Accessing AWS
Explore how users and systems interact with AWS, and the basic deployment and operations concepts that CLF-C02 expects you to know.
Step 1 – How People and Systems Access AWS (Big Picture)
In this module, you will see how you and your applications actually talk to AWS.
At a high level, there are four main ways to access AWS services:
- AWS Management Console
- A web UI (in your browser) for humans.
- Good for: learning, one‑off tasks, visual dashboards.
- AWS Command Line Interface (CLI)
- A text-based tool you run in a terminal (PowerShell, bash, etc.).
- Good for: scripting, automation, repeating the same tasks reliably.
- AWS SDKs (Software Development Kits) and APIs
- Libraries for languages like Python, JavaScript, Java, C#, Go, etc.
- Good for: letting your applications call AWS directly (for example, an app uploading files to S3).
- Infrastructure as Code (IaC) tools
- You define your infrastructure in code or templates instead of clicking in the console.
- AWS-native tool: AWS CloudFormation.
- Also common (but beyond CLF-C02 detail level): Terraform, CDK, etc.
You will also learn about operations and monitoring services that watch what is happening in your AWS account:
- Amazon CloudWatch – metrics, logs, alarms.
- AWS CloudTrail – records who did what, and when (API call history).
- AWS Config – tracks configuration changes and compliance.
- AWS Trusted Advisor – automated best-practice checks (cost, security, etc.).
Keep the exam angle in mind: CLF-C02 expects you to recognize which tool/service is appropriate in a scenario, not to write production-grade automation.
Step 2 – AWS Management Console: The Human-Friendly Interface
The AWS Management Console is usually your first contact point with AWS.
What it is
- A web-based GUI at `https://console.aws.amazon.com`.
- You log in using an IAM user, IAM Identity Center (formerly AWS SSO), or root user (not recommended for everyday use).
What you can do there
- Search for and open services like EC2, S3, RDS.
- Create and configure resources with forms and wizards (e.g., create an EC2 instance by filling in fields).
- View dashboards and metrics (e.g., CloudWatch graphs).
- Use service-specific consoles (e.g., S3 bucket file browser, Lambda code editor).
Visual description
Imagine the console as a control panel:
- Top search bar: type `S3`, `EC2`, etc.
- Left menus: navigate between resource lists and settings.
- Center: main workspace showing tables, charts, or configuration pages.
When to choose the Console (exam perspective)
- You are new to AWS and want to explore.
- You need to quickly check or change a single resource.
- A scenario mentions clicking through a web interface or non-technical stakeholders reviewing resources.
If a question mentions visual dashboards, one-time setup, or a non-programmer user, the Management Console is usually the right answer.
Step 3 – Thought Exercise: Console vs CLI vs SDK
Consider these three mini-scenarios. For each, decide which access method fits best: Console, CLI, or SDK.
- Scenario A: A student wants to quickly upload a few files to an S3 bucket and check that they are visible.
- Scenario B: A DevOps engineer needs to rotate log files every night and move them from one S3 bucket to another automatically.
- Scenario C: A web application written in Python needs to upload user profile pictures directly to S3 when users click "Save".
Pause and decide your answers before reading the suggestions below.
Suggested answers:
- Scenario A → Console: Easy, one-time manual task with a graphical interface.
- Scenario B → CLI (or IaC/script): Needs automation and repeatability (a scheduled script using AWS CLI or similar).
- Scenario C → SDK: The application code needs to talk to AWS (e.g., using the AWS SDK for Python (boto3)).
Use this kind of reasoning on the exam: Who or what is talking to AWS (human vs script vs app)? That usually points to Console vs CLI vs SDK.
Step 4 – AWS CLI and SDKs: Let Scripts and Apps Talk to AWS
The AWS CLI and SDKs use the same underlying AWS APIs, but in different contexts.
AWS Command Line Interface (CLI)
- Installed on your machine or in a server/CI environment.
- You authenticate with access keys or SSO/Identity Center.
- Ideal for automation scripts and repeating tasks.
Example: listing S3 buckets with the AWS CLI:
```bash
Configure your CLI (done once)
aws configure
Then list all S3 buckets in your account
aws s3 ls
```
AWS SDKs (for applications)
- Language-specific libraries: boto3 (Python), AWS SDK for JavaScript, etc.
- Used inside your application code.
Example: uploading a file to S3 using Python (boto3):
```python
import boto3
s3 = boto3.client("s3")
s3.upload_file(
Filename="local_photo.jpg",
Bucket="my-example-bucket",
Key="images/local_photo.jpg"
)
```
You do not need to memorize syntax for the exam, but you should know:
- CLI → used in shell/terminal, good for scripts and admins.
- SDK → used in application code, good for developers building apps.
If a question mentions PowerShell/bash scripts, think CLI. If it mentions code in Python/JavaScript/Java, think SDK.
Step 5 – Infrastructure as Code and AWS CloudFormation (Conceptual)
Modern teams avoid manually clicking in the console for every change. Instead, they use Infrastructure as Code (IaC).
What is Infrastructure as Code?
- You define your infrastructure in files (YAML/JSON or higher-level languages).
- These files describe resources like VPCs, subnets, EC2 instances, S3 buckets, etc.
- Benefits: repeatable, version-controlled, testable, and documented.
AWS CloudFormation (AWS-native IaC)
CloudFormation is AWS’s primary IaC service.
Concepts:
- Template: A file (YAML/JSON) describing your resources.
- Stack: A deployed instance of that template (the actual resources in your account).
- You create/update/delete stacks; CloudFormation figures out what to create, change, or remove.
Very high-level example of a CloudFormation snippet (YAML):
```yaml
Resources:
MyBucket:
Type: AWS::S3::Bucket
Properties:
BucketName: my-example-bucket-12345
```
You do not need to write CloudFormation for CLF-C02. You just need to recognize:
- If the scenario mentions templates, stacks, repeatable deployments, or version-controlling infrastructure, the best answer is usually AWS CloudFormation.
- CloudFormation helps avoid configuration drift (resources becoming inconsistent over time).
Historically, teams often used only the console or manual scripts. IaC with CloudFormation became standard because it reduces human error and makes deployments more reliable and auditable.
Step 6 – Monitoring with Amazon CloudWatch
Amazon CloudWatch is AWS’s main monitoring and observability service.
What CloudWatch does
- Collects metrics: CPU utilization, network traffic, request counts, etc.
- Stores logs: application logs, Lambda logs, system logs.
- Creates alarms: trigger actions when metrics cross thresholds.
- Provides dashboards: graphs and visualizations.
Typical exam associations
- CloudWatch Metrics: “CPU usage of an EC2 instance,” “number of requests to an ALB,” etc.
- CloudWatch Logs: “view Lambda function logs,” “troubleshoot a failing application.”
- CloudWatch Alarms: “send an SNS notification when CPU > 80% for 5 minutes,” “scale out an Auto Scaling group.”
If a question mentions performance, resource utilization, logs, or alarms, CloudWatch is the likely answer.
Visual description: imagine a dashboard with line charts showing CPU usage over time, plus a table of log events you can filter and search.
Step 7 – Governance and Auditing: CloudTrail, Config, Trusted Advisor
Three services often appear together in foundational questions:
1. AWS CloudTrail – “Who did what, and when?”
- Records API calls and console actions in your account.
- Example: User Alice called `RunInstances` on EC2 at 10:32 UTC from IP X.
- Useful for security investigations, audits, and change tracking.
Key phrase: API activity history or audit trail → think CloudTrail.
2. AWS Config – “What does my environment look like, and how has it changed?”
- Records the configuration state of AWS resources over time.
- Can check resources against rules (e.g., all S3 buckets must be encrypted).
- Helps with compliance and governance.
Key phrase: configuration history, compliance rules, resource inventory → think AWS Config.
3. AWS Trusted Advisor – “Am I following best practices?”
- Runs automated checks across your account in categories like:
- Cost optimization (unused resources)
- Performance
- Security (e.g., public S3 buckets)
- Fault tolerance
- Service limits (quotas)
- Shows recommendations and potential savings.
Key phrase: best-practice checks, cost-saving recommendations, security recommendations → think Trusted Advisor.
CLF-C02 often tests your ability to match each service to its primary purpose in scenario questions.
Step 8 – Quick Check: Access Methods
Test your understanding of how to choose between Console, CLI, and SDKs.
A startup wants to build a mobile app that lets users upload photos directly to an S3 bucket. Which is the MOST appropriate way for the app itself to interact with S3?
- Use the AWS Management Console from the phone’s web browser
- Use the AWS CLI installed on the user’s phone
- Use an AWS SDK integrated into the mobile application
- Send the photos by email to an admin who uploads them manually
Show Answer
Answer: C) Use an AWS SDK integrated into the mobile application
The app needs programmatic access to S3, so using an AWS SDK integrated into the mobile application is the correct choice. The Console and CLI are for humans or scripts, not for end-user mobile app flows, and emailing an admin is not scalable or secure.
Step 9 – Quick Check: Monitoring and Governance Services
Match the described need to the correct AWS service.
Your security team needs to review which IAM user deleted an S3 bucket last week. Which AWS service should they use FIRST to find this information?
- Amazon CloudWatch
- AWS CloudTrail
- AWS Config
- AWS Trusted Advisor
Show Answer
Answer: B) AWS CloudTrail
AWS CloudTrail records API calls and console actions, including who did what and when. It is the primary service for investigating who deleted a resource. CloudWatch is for metrics/logs, Config is for configuration state and compliance, and Trusted Advisor is for best-practice recommendations.
Step 10 – Flashcard Review: Key Terms and Services
Flip through these flashcards to reinforce the main concepts from this module.
- AWS Management Console
- A web-based graphical user interface for humans to interact with AWS services, suitable for learning, one-off tasks, and visual dashboards.
- AWS CLI (Command Line Interface)
- A text-based tool used in terminals or scripts to interact with AWS services programmatically, ideal for automation and repeatable tasks.
- AWS SDK
- Language-specific libraries (e.g., for Python, JavaScript, Java) that allow application code to call AWS services programmatically.
- Infrastructure as Code (IaC)
- An approach where infrastructure is defined and managed using code or templates, enabling repeatable, version-controlled deployments.
- AWS CloudFormation
- AWS’s native Infrastructure as Code service that uses templates to create, update, and delete stacks of AWS resources.
- Amazon CloudWatch
- A monitoring and observability service for collecting metrics, logs, and setting alarms for AWS resources and applications.
- AWS CloudTrail
- A service that records AWS API calls and console actions for auditing, security investigations, and change tracking.
- AWS Config
- A service that tracks configuration changes of AWS resources and evaluates them against compliance rules.
- AWS Trusted Advisor
- A recommendation service that checks your AWS environment against best practices in cost, performance, security, fault tolerance, and service limits.
- CloudWatch Alarm
- A configuration in CloudWatch that monitors a metric and triggers actions (such as notifications or scaling) when thresholds are crossed.
Key Terms
- Log
- A record of events and messages generated by applications or infrastructure, often used for debugging and auditing.
- Metric
- A time-ordered set of data points related to a monitored resource or application, such as CPU utilization.
- AWS CLI
- The AWS Command Line Interface, a text-based tool for managing AWS services from a terminal or scripts.
- AWS SDK
- Language-specific libraries that allow application code to interact with AWS services via APIs.
- AWS Config
- A service that records configuration changes of AWS resources and evaluates them against compliance rules.
- AWS CloudTrail
- A service that records AWS API calls and console actions for auditing and security analysis.
- Amazon CloudWatch
- AWS’s monitoring service for metrics, logs, dashboards, and alarms.
- AWS CloudFormation
- An AWS service that lets you model and set up your resources using templates, then manage them as stacks.
- AWS Trusted Advisor
- A service that provides real-time guidance to help you follow AWS best practices in cost, performance, security, and more.
- AWS Management Console
- The browser-based graphical interface for interacting with AWS services.
- Stack (CloudFormation)
- A collection of AWS resources that you manage as a single unit, created and managed from a CloudFormation template.
- Infrastructure as Code (IaC)
- Managing and provisioning infrastructure using machine-readable definition files instead of manual configuration.