Lesson 11 β Enterprise Build Project
Learning Path
βοΈ Phase 2 β AWS Cloud Security
π Module 05 β Amazon EC2 Security
π― Project Objective
Section titled βπ― Project ObjectiveβWelcome to the capstone project for Module 05 β Amazon EC2 Security.
In this project, you will build a secure enterprise-grade EC2 environment for CloudNova Technologies.
This project combines everything learned throughout the module into a single deployment that closely resembles how cloud engineers build secure production workloads in real organisations.
By the end of this project, you will be able to:
- Design a secure EC2 deployment.
- Deploy application servers using enterprise standards.
- Secure compute resources using IAM Roles.
- Configure encrypted storage.
- Enable Systems Manager administration.
- Implement monitoring and backup.
- Validate the deployment using enterprise security checklists.
πΌ Business Scenario
Section titled βπΌ Business ScenarioβCloudNova Technologies is launching a brand-new Learning Management System (LMS).
The company expects:
- Thousands of concurrent users
- Student assessments
- Course streaming
- AI-powered learning features
- 24Γ7 availability
As the Cloud Security Engineer, you are responsible for deploying the first secure production environment.
Your deployment must follow CloudNovaβs enterprise security standards.
π’ Enterprise Architecture
Section titled βπ’ Enterprise Architectureβ Internet β AWS Shield Standard β AWS WAF β Application Load Balancer β Public Subnets (Multi-AZ) β Auto Scaling Group (EC2) ββββββββββββββββββββ΄βββββββββββββββββββ β β Private App Subnet A Private App Subnet B β β EC2 App Server 01 EC2 App Server 02 β β ββββββββββββββββ¬βββββββββββββββββββββββ β Amazon RDS (Private) β Amazon S3 (Application Files) βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Supporting Services
IAM Roles
AWS Systems Manager
CloudWatch
CloudTrail
AWS Backup
AWS KMS
Amazon EBS Encryptionπ Project Requirements
Section titled βπ Project RequirementsβYour environment must include:
| Component | Required |
|---|---|
| Amazon Linux 2023 | β |
| Amazon VPC | β |
| Private Subnets | β |
| Security Groups | β |
| IAM Role | β |
| Systems Manager | β |
| CloudWatch Agent | β |
| Encrypted EBS | β |
| Auto Scaling | β |
| Application Load Balancer | β |
| AWS Backup | β |
| CloudTrail | β |
π Phase 1 β Prepare the Environment
Section titled βπ Phase 1 β Prepare the EnvironmentβVerify the following already exist:
- CloudNova-Prod-VPC
- Public Subnets
- Private Application Subnets
- Internet Gateway
- NAT Gateway
- Route Tables
- Security Groups
Review the networking configuration before launching compute resources.
π Phase 2 β Deploy the EC2 Infrastructure
Section titled βπ Phase 2 β Deploy the EC2 InfrastructureβCreate a Launch Template.
Configuration:
| Setting | Value |
|---|---|
| Name | CloudNova-Web-Template |
| AMI | Amazon Linux 2023 or CloudNova-Secure-AMI-v1 |
| Instance Type | t3.micro |
| IAM Role | CloudNova-EC2-Role |
| Root Volume | 20 GiB gp3 |
| Encryption | Enabled |
Launch the EC2 instances into the Private Application Subnets.
π Phase 3 β Configure IAM
Section titled βπ Phase 3 β Configure IAMβVerify the EC2 instances use:
CloudNova-EC2-RoleRequired permissions:
- AmazonSSMManagedInstanceCore
- CloudWatchAgentServerPolicy
- Read-only access to required Amazon S3 resources (or a custom least-privilege policy)
Verify:
aws sts get-caller-identityπ Phase 4 β Configure Systems Manager
Section titled βπ Phase 4 β Configure Systems ManagerβConfirm:
- Managed Node is online.
- Session Manager works.
- Run Command executes successfully.
Execute:
hostname
df -h
uptimeπ Phase 5 β Secure Storage
Section titled βπ Phase 5 β Secure StorageβVerify:
- Encrypted EBS
- AWS KMS
- Snapshot capability
Create:
CloudNova-Production-BackupVerify encryption remains enabled.
π Phase 6 β Configure Monitoring
Section titled βπ Phase 6 β Configure MonitoringβInstall the CloudWatch Agent.
Verify:
- CPU
- Memory
- Disk
- Network
Create CloudWatch Alarms:
| Metric | Threshold |
|---|---|
| CPU | >80% |
| Disk | >90% |
| Status Checks | Failed |
π Phase 7 β Configure Logging
Section titled βπ Phase 7 β Configure LoggingβReview CloudTrail.
Verify:
- RunInstances
- StopInstances
- CreateSnapshot
- ModifyInstanceAttribute
Record:
- Event Time
- User
- Resource
π Phase 8 β Configure Backup
Section titled βπ Phase 8 β Configure BackupβCreate:
Daily Backup Plan
02:00 AMRetention:
30 DaysAssign:
- EC2 Instance
- EBS Volumes
π Phase 9 β Configure Auto Scaling
Section titled βπ Phase 9 β Configure Auto ScalingβCreate:
| Setting | Value |
|---|---|
| Minimum | 2 |
| Desired | 2 |
| Maximum | 6 |
Scaling Policy:
CPU >70%
β
Launch New InstanceScale-In Policy:
CPU <30%
β
Remove Instanceπ Phase 10 β Validate Security
Section titled βπ Phase 10 β Validate SecurityβVerify every server has:
β Private IP
β No Public IP
β IAM Role
β Session Manager
β Encrypted Storage
β CloudWatch Agent
β Backup Enabled
β Correct Security Group
π Project Tasks
Section titled βπ Project TasksβComplete the following tasks.
Task 1 β Launch Secure EC2 Instances
Section titled βTask 1 β Launch Secure EC2 InstancesβDeploy:
CloudNova-App-Server-01
CloudNova-App-Server-02Requirements:
- Amazon Linux 2023
- Private Subnet
- IAM Role
- Encrypted Storage
- Enterprise Tags
Task 2 β Verify IAM
Section titled βTask 2 β Verify IAMβRun:
aws sts get-caller-identityConfirm:
Assumed Roleis displayed.
Task 3 β Verify Systems Manager
Section titled βTask 3 β Verify Systems ManagerβConnect using:
Session Manager
Run:
hostname
whoami
uptimeTask 4 β Verify Storage
Section titled βTask 4 β Verify StorageβReview:
- Encrypted EBS
- Snapshots
- AWS KMS Key
Task 5 β Verify Monitoring
Section titled βTask 5 β Verify MonitoringβConfirm:
CloudWatch Dashboard displays:
- CPU
- Memory
- Disk
- Network
Task 6 β Verify Logging
Section titled βTask 6 β Verify LoggingβReview CloudTrail events for:
- EC2 Launch
- Snapshot Creation
- IAM Role Association
Task 7 β Verify Backup
Section titled βTask 7 β Verify BackupβReview:
AWS Backup
β
Protected Resources
Confirm successful backup jobs.
Task 8 β Verify Auto Scaling
Section titled βTask 8 β Verify Auto ScalingβTerminate one EC2 instance from the Auto Scaling Group.
Observe:
- Health Check Failure
- Automatic Replacement
- New Instance Registration
- Load Balancer Health
π» AWS CLI Lab
Section titled βπ» AWS CLI LabβDescribe EC2 Instances
Section titled βDescribe EC2 Instancesβaws ec2 describe-instancesDescribe Volumes
Section titled βDescribe Volumesβaws ec2 describe-volumesDescribe IAM Identity
Section titled βDescribe IAM Identityβaws sts get-caller-identityDescribe Managed Nodes
Section titled βDescribe Managed Nodesβaws ssm describe-instance-informationDescribe CloudWatch Alarms
Section titled βDescribe CloudWatch Alarmsβaws cloudwatch describe-alarmsDescribe Auto Scaling Groups
Section titled βDescribe Auto Scaling Groupsβaws autoscaling describe-auto-scaling-groupsDescribe Backup Jobs
Section titled βDescribe Backup Jobsβaws backup list-backup-jobsDescribe CloudTrail Events
Section titled βDescribe CloudTrail Eventsβaws cloudtrail lookup-eventsπ Project Deliverables
Section titled βπ Project DeliverablesβDocument the following evidence.
| Evidence | Required |
|---|---|
| VPC Architecture | β |
| EC2 Dashboard | β |
| Security Groups | β |
| IAM Role | β |
| Session Manager | β |
| CloudWatch Dashboard | β |
| CloudTrail Events | β |
| AWS Backup | β |
| Auto Scaling Group | β |
| Application Load Balancer | β |
| Encrypted EBS | β |
| Snapshots | β |
| AWS CLI Output | β |
π Suggested Project Folder Structure
Section titled βπ Suggested Project Folder StructureβEnterprise-EC2-Build-Project/
βββ README.mdβββ Architecture/β βββ Architecture-Diagram.pngβ βββ Network-Diagram.pngβ βββ Security-Architecture.pngββββ Screenshots/β βββ EC2.pngβ βββ IAM-Role.pngβ βββ Session-Manager.pngβ βββ CloudWatch.pngβ βββ CloudTrail.pngβ βββ Backup.pngβ βββ AutoScaling.pngβ βββ LoadBalancer.pngββββ Evidence/β βββ CLI-Commands.mdβ βββ Validation-Checklist.mdβ βββ Security-Review.mdββββ Lessons-Learned.mdβ Project Validation Checklist
Section titled ββ Project Validation Checklistβ| Validation Item | Status |
|---|---|
| Private Subnets Used | β |
| No Public IPs | β |
| IAM Role Attached | β |
| Session Manager Operational | β |
| EBS Encryption Enabled | β |
| CloudWatch Agent Installed | β |
| CloudWatch Alarms Configured | β |
| CloudTrail Enabled | β |
| AWS Backup Configured | β |
| Auto Scaling Operational | β |
| Load Balancer Healthy | β |
| Security Groups Reviewed | β |
| EC2 Instances Patched | β |
π Project Success Criteria
Section titled βπ Project Success CriteriaβYour project is complete when:
- Two secure EC2 instances are deployed.
- All instances use IAM Roles.
- Storage is encrypted.
- Session Manager replaces SSH for administration.
- Monitoring and logging are operational.
- Automated backups are configured.
- Auto Scaling is functional.
- The Application Load Balancer distributes traffic successfully.
- The environment complies with CloudNovaβs enterprise security standards.
π Bonus Challenges
Section titled βπ Bonus ChallengesβChallenge 1 β Blue/Green Deployment
Section titled βChallenge 1 β Blue/Green DeploymentβCreate a second Launch Template using an updated AMI and perform a blue/green deployment with minimal downtime.
Challenge 2 β Harden the Security Groups
Section titled βChallenge 2 β Harden the Security GroupsβReview all Security Groups and remove any unnecessary inbound or outbound rules while ensuring application functionality.
Challenge 3 β Create a Custom CloudWatch Dashboard
Section titled βChallenge 3 β Create a Custom CloudWatch DashboardβBuild a dashboard displaying:
- CPU Utilisation
- Memory Usage
- Disk Usage
- Network Traffic
- Auto Scaling Activity
- EC2 Health Checks
Challenge 4 β Simulate Disaster Recovery
Section titled βChallenge 4 β Simulate Disaster Recoveryβ- Create a manual EBS Snapshot.
- Simulate the loss of an application server.
- Restore the snapshot.
- Launch a replacement EC2 instance.
- Verify the application can be recovered successfully.
π‘ What Youβve Learned
Section titled βπ‘ What Youβve LearnedβCongratulations!
By completing this project, you have applied the complete EC2 security lifecycle used in enterprise environments.
You have successfully demonstrated practical experience with:
- Secure EC2 deployment
- IAM Roles and least privilege
- Amazon EBS encryption and AWS KMS
- AWS Systems Manager and Session Manager
- EC2 hardening and patch management
- Amazon CloudWatch monitoring
- AWS CloudTrail auditing
- AWS Backup and disaster recovery
- Auto Scaling Groups
- Application Load Balancers
- Enterprise security validation
These are the same core skills expected of Cloud Engineers, Cloud Security Engineers and DevSecOps professionals working with production AWS environments.
π Next Lesson
Section titled βπ Next Lessonββ‘οΈ Lesson 12 β Module Review