Skip to content

eeeemune/Infra-Notes

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

213 Commits
 
 
 
 
 
 

Repository files navigation

Contents

Docker

  • 💚 How to Run a Command on a Docker Image Stored in AWS ECR
    • 💛 Authenticate Docker with ECR
      • 🤍 Example
    • 💛 Pull the Image From ECR
    • 💛 Run the Image With a Command
    • 💛 Start an Interactive Shell
  • 💚 What Is Docker Mount?
    • 💛 Basic Syntax
    • 💛 Example
      • 🤍 What It Means:
    • 💛 Why Use This?
    • 💛 Other Mount Use Cases
    • 💛 Reference
  • 💚 How to Check Environment Variables in a Docker Container
    • 💛 1. While Running a Container
      • 🤍 Option A: Use ‘docker exec’
      • 🤍 Option B: Use a Shell
  • or
  • or
    • 💛 2. When Creating a Container
    • 💛 3. From ‘docker inspect’
    • 💛 References
  • 💚 OCI (Open Container Images) and Registries
    • 💛 What is OCI?
    • 💛 OCI Images
    • 💛 OCI Registries
    • 💛 Helm + OCI
      • 🤍 Why Use OCI for Helm Charts?
    • 💛 References
  • 💚 Command
  • 💚 Explain
    • 💛 Sign in Docker with Terminal
    • 💛 Sign in Docker by AWS Profile
  • 💚 Reference

GitHubActions

  • 💚 How to Configure Git on Your Terminal
    • 💛 1. Set Your Identity (Required)
    • 💛 2. Check Your Config
    • 💛 3. Set Credential Helper (avoid typing password/PAT every time)
      • 🤍 macOS
      • 🤍 Linux (simple store)
    • 💛 4. Set Editor (Optional)
      • 🤍 Vim
    • 💛 5. Enable Colored Output (Pretty UI)
    • 💛 7. Setup SSH Instead of Password
  • Hi eeeemune! You've successfully authenticated, but GitHub does not provide shell access.
    • 💛 Example Full Setup (Quick Copy)
    • 💛 References
  • 💚 How to set a team as Auto-Assigned Reviewers
    • 💛 Make Sure You Have a GitHub Team
    • 💛 Create or Edit a File
  • All files will be reviewed by the backend team
  • All files in the frontend folder will be reviewed by the frontend team - 💛 Enable CODEOWNERS Auto-Assignment in Settings - 💛 Things to Note
  • 💚 How to Pull a Specific Branch from a Remote Git Repository
    • 💛 1. Check Remote Branches
    • 💛 2. Pull a Specific Branch (first time)
    • 💛 3. Pull Updates (branch already exists locally)
    • 💛 Bonus: Just Download Without Switching
    • 💛 References
  • 💚 How to Use git diff Command
    • 💛 What does it do?
    • 💛 Common Usages
      • 🤍 Show unstaged changes (what you've edited but not added)
      • 🤍 Show staged changes (what you've added with )
      • 🤍 Show everything (staged + unstaged)
    • 💛 Compare Between Branches
    • 💛 Compare Between Commits
    • 💛 See Only File Names (not full diff)
    • 💛 Compare with Remote Branch
    • 💛 References
  • 💚 What is the ‘runner’?
    • 💛 GitHub Actions Runner
    • 💛 Where does the runner live?
    • 💛 Example

Kubernetes

  • 💚 What is Karpenter?
    • 💛 Karpenter
    • 💛 Why Do We Need It?
    • 💛 How It Works
      • 🤍 Flow
    • 💛 What Makes Karpenter Special?
      • 🤍 Traditional Cluster Autoscaler
      • 🤍 Karpenter
    • 💛 Simple Config Example
    • 💛 References
  • 💚 Helm Chart and Release
    • 💛 What is a Helm Release?
    • 💛 Example
    • 💛 In Terraform
  • 💚 ECS to EKS Migration Guide
    • 💛 Before You Start…
      • 🤍 Essential Concept
      • 🤍 The Big Picture
      • 🤍 Overal Structure
    • 💛 IAM Setup
      • 🤍 Why Do We Need IAM Roles?
      • 🤍 Cluster Role
  • iam.tf
  • Create the role
  • Attach the required policy - 🤍 Node Role
  • Create the role
  • Nodes need THREE policies: - 🤍 User Access
  • Import your IAM user
  • Add yourself to the cluster's access list
  • Give yourself admin permissions
    • 💛 Creating the EKS Cluster
      • 🤍 The Cluster Itself
  • cluster.tf - 🤍 Node Groups - 🤍 Essential Add-ons
  • DNS for service discovery (pods find each other by name - like a dns server in K8s)
  • Networking (assigns IPs to pods)
  • Network routing
  • Metrics (needed for auto-scaling)
    • 💛 Networking & Security Groups
      • 🤍 Why This Matters?
      • 🤍 EKS → RDS
      • 🤍 EKS → Redis(ElastiCache)
      • 🤍 ALB → EKS Pods
  • First, create a security group for the ALB
  • Then allow ALB to reach EKS nodes
    • 💛 Load Balancer
      • 🤍 Create the ALB
      • 🤍 Create HTTPS Listener
      • 🤍 Create Target Groups
      • 🤍 Create Listener Rules
      • 🤍 Connect ALB to EKS (TargetGroupBinding)
    • 💛 Managing Secrets
      • 🤍 Background - The Problem
      • 🤍 Variable Flows
      • 🤍 Fetch Secrets from SSM by Terraform
  • Get all parameters under /chartmetric/shared/
  • Get environment-specific parameters - 🤍 Create Kubernetes Secrets - 🤍 Use Secrets in Deployments
  • In your deployment spec:
  • This value will WIN over anything in api-secrets
  • This loads from secrets (but env above takes precedence)
    • 💛 Deploying Applications
      • 🤍 Basic Deployment
      • 🤍 Creating a Service
      • 🤍 Horizontal Pod Autoscaler (HPA)
    • 💛 Redis Configuration
      • 🤍 The Setup
      • 🤍 Define Redis in Environment Config
  • environments.tf - 🤍 Create Redis Clusters
  • redis.tf - 🤍 Connect Pods with Redis
  • In deployment spec:
    • 💛 DNS & Traffic Migration
      • 🤍 How Can We Migrate with Zero-Downtime?
      • 🤍 Create DNS Records
      • 🤍 Update CloudFront
      • 🤍 Attach WAF
  • 💚 How to Use Secrets in Kubernetes
    • 💛 Create a Secret
    • 💛 Check The Secret
      • 🤍 List Up Secrets
      • 🤍 See The Value for Secret
    • 💛 References
  • 💚 Objectives
  • 💚 Control Plane
  • 💚 Kubelet
    • 💛 Node-level Component
  • 💚 Reference
  • 💚 Kubernetes Services
    • 💛 What is a Service?
    • 💛 Why Use a Service?
    • 💛 Types of Services
      • 🤍 ClusterIP
      • 🤍 NodePort
      • 🤍 LoadBalancer
      • 🤍 ExternalName
    • 💛 How Do Services Know Where to Send Traffic?
      • 🤍 Example: Service with Selector
    • 💛 What if There's No Selector?
    • 🤍 Summary
  • Reference
  • 💚 Reference
  • 💚 Objectives
  • 💚 Deployments
    • 💛 What is a Deployment?
    • 💛 Why is it Useful?
    • 💛 What Happens If a Pod Dies?
      • 🤍 Real-Life Example
    • 💛 Summary
  • 💚 Background
    • 💛 Monoliths
      • 🤍 Disadvantages of Monoliths
    • 💛 Microservices
      • 🤍 How to Run Microservices
  • 💚 Kubernetes
    • 💛 What is the Kubernetes?
    • 💛 Key Goals
      • 🤍 Maximize Capacity
      • 🤍 Adapt to Demand
      • 🤍 Don’t Go Dark
      • 🤍 Abstraction
    • 💛 Notations
      • 🤍 Pod and Container
      • 🤍 Node and Cluster
    • 💛 Abstracted Infrastructure of Kubernetes
      • 🤍 Why Abstracted Infra is Needed?
      • 🤍 Immutable Template
      • 🤍 Benefits
    • 💛 Self-Healing in Kubernetes
      • 🤍 Ideal State vs Actual State
      • 🤍 Update Mechanisms
      • 🤍 Labels
      • 🤍 Services
  • 💚 References
  • 💚 What is Helm?
    • 💛 Short Answer
    • 💛 Why Use Helm?
    • 💛 What Is a Helm Chart?
      • 🤍 Example:
    • 💛 Helm Workflow
    • 🤍 Summary

Harbor

  • 💚 How to Check Harbor Connection
    • 💛 Background
    • 💛 How to check
      • 🤍 Command
      • 🤍 Succeed
      • 🤍 Failure
  • 💚 Harbor
    • 💛 What is Harbor?
    • 💛 Key Features
      • 🤍 Stores container images & Helm charts (OCI format)
      • 🤍 Controls who can see or change things (RBAC)
      • 🤍 Scans for security issues
      • 🤍 Signs and verifies images (trust)
      • 🤍 Replicates to other registries
      • 🤍 Login with your company account (LDAP/AD)
      • 🤍 Has a website and API
    • 💛 How Harbor fits with Helm and OCI
    • 💛 Typical Use Cases
    • 💛 References

Others

  • 💚 Data-Driven Design Pattern
    • 💛 What is Data-Driven Design Pattern?
    • 💛 Why Use It?
    • 💛 Example
      • 🤍 Traditional (Hard-coded)
      • 🤍 Data-Driven
    • 💛 Summary
  • 💚 How to Connect a Slack App
    • 💛 Create a Slack Incoming Webhook
    • 💛 Enable Socket Mode
    • 💛 Add a Coolify Webhook Trigger
      • 🤍 Configure a Webhook
      • 🤍 Set the Webhook to Your Application
  • 💚 How to Get HTTP Certificate
    • 💛 Install Nginx and Certbot
    • 💛 Configure Nginx as reverse proxy
  • /etc/nginx/sites-available/mcp
    • 💛 Enable the site
    • 💛 Obtain SSL certificate
    • 💛 Enable auto-renual
  • 💚 How to Connect a Slack App

    • 💛 Create a Slack Incoming Webhook
    • 💛 Enable Socket Mode
    • 💛 Add a Coolify Webhook Trigger
      • 🤍 Configure a Webhook
      • 🤍 Set the Webhook to Your Application
  • 💚 How to Connect a Slack App

  • 💚 How to Connect a Slack App

    • 💛 Create a Slack Incoming Webhook

    • 💛 Enable Socket Mode

    • 💛 Add a Coolify Webhook Trigger

      • 🤍 Configure a Webhook
      • 🤍 Set the Webhook to Your Application
    • 💛 Create a Slack Incoming Webhook

    • 💛 Enable Socket Mode

    • 💛 Add a Coolify Webhook Trigger

      • 🤍 Configure a Webhook
      • 🤍 Set the Webhook to Your Application
  • 💚 How VPN Works?
    • 💛 What is a VPN?
    • 💛 Why use a VPN?
    • 💛 How VPN changes network behavior
      • 🤍 Networking Concepts Involved
    • 💛 Types of VPNs
    • 💛 What gets affected?
    • 💛 Common VPN Protocols
    • 💛 What does encrypted mean?
    • 💛 Common Use Cases
    • 💛 References

Network

  • 💚 How to Set Up VPN with Wireguard
    • 💛 Install Wireguard
    • 💛 Generate keys on each machine
    • 💛 Set Up Server
  • Client 1
  • Client 2
    • 💛 Set Up Client
  • 💚 What is NAT?
    • 💛 NAT = Network Address Translation
    • 💛 Why do we need NAT?
    • 💛 How does it work?
      • 🤍 Simple Example
    • 💛 Types of NAT
    • 💛 Where is NAT used?
    • 💛 References

Linux

  • 💚 Setting the Root Password for the First Time
    • 💛 Step-by-Step
  • 💚 How to Get My IP on Linux
    • 💛 Public
      • 🤍 IPv6
  • 2603:3024:269:2200::bb22 - 🤍 IPv4
    • 💛 Private
  • 10.1.10.198
  • 💚 How to Create a New User for SSH
    • 💛 1. Add the User
    • 💛 2. Add User to Group (optional)
    • 💛 3. Create Folder
    • 💛 4. Add Public SSH Key
    • 💛 5. Test the Login
      • 🤍 Example
    • 💛 References

GCP

  • 💚 How to Create OAuth Client
    • 💛 Reference
    • 💛 Create OAuth Client
      • 🤍 Go to Google Auth Platform → Clients Tab
      • 🤍 Create Client
    • 💛 Save Auth Information
      • 🤍 Download Auth JSON

Python

  • 💚 How to Use Poetry
    • 💛 What is Poetry?
    • 💛 Quick Start
      • 🤍 1. Install Poetry
      • 🤍 2. Create a New Project
      • 🤍 3. Add Dependencies
      • 🤍 4. Install Everything (existing project)
      • 🤍 5. Run Commands Inside Environment
      • 🤍 6. Update Dependencies
      • 🤍 7. Check Dependency Graph
      • 🤍 8. Publish Your Package
    • 💛 Useful Extras
    • 💛 Workflow Example
  • 💚 How to Use requirements.txt in Python
    • 💛 What is requirements.txt?
    • 💛 Install Packages from requirements.txt
    • 💛 Create Your Own requirements.txt
    • 💛 4. Use with Virtual Environments
    • 💛 Best Practices
  • Web framework
    • 💛 References

DNS

  • 💚 What Does Your Connection is Not Private Mean?
    • 💛 What Is SSL?
    • 💛 Why This Error Happens
      • 🤍 1. Expired or invalid SSL certificate
      • 🤍 2. Your computer’s date/time is wrong
      • 🤍 3. Man-in-the-middle (MITM) attack
      • 🤍 4. Untrusted certificate authority (CA)
    • 💛 What You See
    • 💛 Developer Tips
    • 💛 References

Terraform

  • 💚 Add a New GitHub Member with Terraform
    • 💛 Go to the Files
  • teams.terraform → defines GitHub teams
  • membership.terraform → defines who’s in each team
    • 💛 Add a New Member
  • membership.tf
    • 💛 Apply Terraform
    • 💛 Commit the Change & Create a PR

TroubleShootings

  • 💚 Terraform Tutorial
    • 💛 What is Terraform?
      • 🤍 Example
    • 💛 Terraform Workflow
    • 💛 Core Concepts
    • 💛 Variables & Outputs
      • 🤍 variables.tf
      • 🤍 main.tf
      • 🤍 outputs.tf
    • 💛 State Management
    • 💛 Modules
      • 🤍 Example
    • 💛 Best Practices
    • 💛 References

AWS

  • 💚 How to connect your terminal to EKS
    • 💛 Prerequisites
      • 🤍 Required tools
    • 💛 Steps
      • 🤍 1. Verify AWS access
      • 🤍 2. Generate ‘kubeconfig’ for EKS
  • Real example - 🤍 3. Select and check current context - 🤍 4. Test

Terrraform

  • 💚 Terraform Module
    • 💛 What is a Module?
    • 💛 Basic Structure
    • 💛 Example
      • 🤍 Configure the Module
  • variables.tf (input)
  • main.tf
  • outputs.tf (output) - 🤍 Use the Module
    • 💛 Module Source Types
      • 🤍 Local Module
      • 🤍 GitHub Module
      • 🤍 Terraform Registry
    • 💛 Best Practices
    • 💛 References

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published