DevOps & Developer Tools β
Automate Everything from Code to Cloud
CloudFormation, CDK, CodePipeline, CodeBuild, CodeDeploy, CodeCommit β infrastructure as code and CI/CD services that automate the path from code commit to production deployment.
Why DevOps on AWS?
DevOps on AWS means automating every step from infrastructure provisioning (IaC) to application deployment (CI/CD). The goal: push code β automatically build, test, and deploy to production β with rollback if anything fails.
Infrastructure as Code (IaC)
- Define infrastructure in code (templates or programs)
- Version-controlled, repeatable, testable
- Create identical environments on demand
- Delete a stack β all resources cleaned up
- Services: CloudFormation, CDK
CI/CD Pipeline
- Automate build, test, and deploy on every commit
- Catch bugs early with automated testing
- Deploy with blue/green, canary, or rolling strategies
- Rollback automatically on failure
- Services: CodePipeline, CodeBuild, CodeDeploy
Services
| Service | Category | What It Does | Best For |
|---|---|---|---|
| CloudFormation | IaC | Declarative templates (YAML/JSON) β AWS resources | All AWS teams; exam context; simple-to-medium complexity |
| CDK | IaC | Programmatic IaC (Python/Java/TS) β synthesizes to CFN | Dev teams; complex logic; reusable constructs; unit testing infra |
| CodePipeline | CI/CD | Orchestrates end-to-end release pipelines | Automating source β build β test β deploy workflows |
| CodeBuild | CI/CD | Fully managed build service (compile, test, package) | Running builds without managing Jenkins/build servers |
| CodeDeploy | CI/CD | Automated deployments to EC2, ECS, Lambda | Blue/green, canary, and rolling deployments with rollback |
| CodeCommit | Source | Managed Git repositories | Private repos within AWS (being deprecated β prefer GitHub) |
| CodeArtifact | Artifacts | Managed artifact repository (npm, Maven, pip) | Caching and hosting private packages |
Decision Guide
| If you need⦠| Use⦠|
|---|---|
| Define infrastructure in a simple declarative template | CloudFormation |
| Write infrastructure with loops, conditions, and unit tests | CDK |
| Orchestrate a multi-stage release pipeline | CodePipeline |
| Compile code, run tests, produce artifacts | CodeBuild |
| Deploy to EC2/ECS/Lambda with blue/green or canary | CodeDeploy |
| Host private Git repositories in AWS | CodeCommit (or GitHub) |
| Cache npm/Maven/pip packages privately | CodeArtifact |
| Multi-cloud IaC (AWS + Azure + GCP) | Terraform (not AWS-native) |
| Scenario | CloudFormation | CDK |
|---|---|---|
| Simple stacks, small teams | β Simpler to start | Overkill |
| Complex logic (loops, inheritance) | Limited | β Full language power |
| Unit testing infrastructure | Not possible | β pytest / JUnit / Jest |
| IDE autocomplete & type safety | Limited (YAML) | β Full IDE support |
| Reusable components across teams | Nested stacks (meh) | β Construct libraries |
| AWS exam context | β Primary exam focus | Secondary |
Pipeline Flow
CodePipeline orchestrates this entire flow β connecting source, build, and deploy stages into an automated release pipeline that triggers on every code push.
IaC Pipeline
- Template changes pushed to Git
- CodePipeline triggers
- CloudFormation Change Set created
- Manual approval β execute
- Infrastructure updated safely
App Pipeline
- Application code pushed to Git
- CodeBuild compiles + tests
- Produces deployable artifact
- CodeDeploy rolls out (blue/green)
- Auto-rollback on health check failure
AWS DevOps = IaC (CloudFormation/CDK) + CI/CD (CodePipeline/CodeBuild/CodeDeploy). Together they automate the entire lifecycle: infrastructure and application code flow from Git to production with testing, approval gates, and automatic rollback.