Skip to content

CherokeeBoose/Week-10-Notes

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

1 Commit
Β 
Β 

Repository files navigation

Week 10: DevOps & AWS Developer Tools

Git, CodeCommit, CI/CD, CodeBuild, CodeDeploy, CodePipeline

Notes:

  • Pull code from Git β†’ AWS CodeCommit
  • Push code from CodeCommit β†’ Git
  • Manage CodeCommit repository branches
  • Understand CI/CD fundamentals
  • Compare CI/CD paradigms
  • Utilize common DevOps tools
  • Design automation pipelines

πŸ“š Topic Overview

2.1 Working With Code Repositories

Git & CodeCommit Fundamentals

  • Git: Distributed version control, local-first
  • CodeCommit: AWS-managed Git service
  • Pull: fetch + merge (remote β†’ local)
  • Push: upload local commits β†’ remote

Essential Git Commands

git clone git config --local user.name "Name" git config --local user.email "Email" git add git commit -m "message" git push -u origin main git pull git log git branch git checkout git fetch origin

2.2 Branching Strategy

Benefits

  • Enables parallel development
  • Maintains main branch stability
  • Structures change management

Workflow Example

Create branch

git checkout -b MyNewBranch

Push to CodeCommit

git push origin MyNewBranch

Fetch in new environment

git fetch origin git checkout MyNewBranch

πŸ”„ CI/CD Concepts

Goals

  • Automate integration & deployment
  • Minimize human error
  • Accelerate delivery
  • Enhance team collaboration

CI (Continuous Integration)

Frequent code merges with automated validation

CD Comparison

Model Trigger Characteristic
Continuous Delivery Manual approval Deployment-ready
Continuous Deployment Automated No human gates

Pipeline Stages

  1. Code: Developer commits
  2. Build: Compile & package
  3. Test: Multiple testing layers
  4. Release: Version artifacts
  5. Deploy: Environment deployment
  6. Monitor: Health tracking

πŸ› οΈ AWS Developer Tools

4.1 AWS CodeCommit

  • Source control service
  • Version management
  • Event triggers
  • Pipeline integration

4.2 AWS CodeBuild

  • Build automation
  • Test execution
  • Parallel processing
  • CloudWatch logging

4.3 AWS CodeDeploy

Features:

  • Multiple deployment targets
  • AppSpec configuration
  • Deployment strategies
  • Automatic rollbacks

4.4 AWS CodePipeline

graph LR A[CodeCommit] --> B[CodeBuild] B --> C[CodeDeploy] C --> D[Production]

4.5 AWS X-Ray

  • Request tracing
  • Performance analysis
  • Microservice debugging

4.6 Amazon CloudWatch

  • Monitoring platform
  • Metrics collection
  • Pipeline insights
  • Alerting system

πŸš€ Git Command Reference Guide

πŸ› οΈ Setup & Configuration

Initial setup of Git identity

git config --global user.name "Your Name" git config --global user.email "your.email@example.com"

Repository setup

git init # πŸ“ Create new Git repo git clone # πŸ“₯ Clone existing repo

πŸ“‹ Basic Operations

Core commands

git status # πŸ“Š Show working tree status git add # βž• Stage file for commit git add . # βž• Stage all changes git commit -m "" # πŸ’Ύ Record changes git push # ⬆️ Upload to remote git pull # ⬇️ Download from remote

🌿 Branch Management

Branch operations

git branch # πŸ“ List branches git branch # ✨ Create branch git checkout # πŸ”„ Switch branches git checkout -b # πŸ†• Create & switch git merge # πŸ”— Merge branches git branch -d # πŸ—‘οΈ Delete branch

πŸ‘€ Inspection & Comparison

View changes

git log # πŸ“œ View history git log --oneline # πŸ“œ Compact history git diff # πŸ” Show changes git diff --staged # πŸ” Show staged changes git show # πŸ“– Show commit details

↩️ Change Management

Undo operations

git restore # βͺ Discard changes git reset # ❌ Unstage changes git reset --hard HEAD # ⚠️ Reset everything git revert # ↩️ Undo commit

🌐 Remote Operations

Remote repository commands

git remote -v # πŸ“‘ List remotes git fetch # πŸ“₯ Get remote changes git push origin # ⬆️ Upload branch git pull origin # ⬇️ Download branch

πŸ“¦ Stash Operations

Temporary storage

git stash # πŸ’Ό Save changes git stash list # πŸ“‹ List saves git stash pop # πŸ“€ Apply & remove git stash apply # πŸ“₯ Apply & keep

🎯 Best Practices

  • ✍️ Write clear commit messages
  • πŸ”„ Pull before pushing
  • 🌿 Use feature branches
  • 🎯 Keep commits focused
  • πŸ“ Document significant changes

πŸ”„ Common Workflows

Feature development

git checkout -b feature/new-feature git add . git commit -m "✨ Add new feature" git push origin feature/new-feature

Sync with main

git checkout main git pull git checkout feature/new-feature git merge main

Complete feature

git checkout main git merge feature/new-feature git push

πŸ”§ Advanced Operations

History modification

git rebase -i HEAD~3 # πŸ“ Interactive rebase git commit --amend # ✏️ Edit last commit git cherry-pick # πŸ’ Copy commit

Debugging tools

git bisect start # πŸ” Find bugs git blame # πŸ‘€ Show authors git reflog # πŸ“œ Reference log

🏷️ Release Management

Tags and versions

git tag # πŸ“‹ List tags git tag -a v1.0 -m # 🏷️ Create tag git push --tags # ⬆️ Upload tags

πŸ“š Additional Resources

AWS Documentation AWS Developer Tools Documentation AWS CI/CD Best Practices CodeDeploy User Guide CodeDeploy Security Guide CodeDeploy Best Practices Git & GitHub Resources Git Official Documentation GitHub Learning Guides Git Cheat Sheet (PDF)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors