<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: Rahul Joshi</title>
    <description>The latest articles on Forem by Rahul Joshi (@17j).</description>
    <link>https://forem.com/17j</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F1524770%2F09c3d179-30ac-4ff6-99ac-d78fbecdde6a.png</url>
      <title>Forem: Rahul Joshi</title>
      <link>https://forem.com/17j</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/17j"/>
    <language>en</language>
    <item>
      <title>Day 8 — IAM &amp; AWS CLI</title>
      <dc:creator>Rahul Joshi</dc:creator>
      <pubDate>Tue, 19 May 2026 05:27:58 +0000</pubDate>
      <link>https://forem.com/17j/day-8-iam-aws-cli-3li3</link>
      <guid>https://forem.com/17j/day-8-iam-aws-cli-3li3</guid>
      <description>&lt;p&gt;Cloud security starts with one thing:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Who can access what?&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;That’s exactly where &lt;strong&gt;IAM (Identity and Access Management)&lt;/strong&gt; comes in.&lt;/p&gt;

&lt;p&gt;Whether you're:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;a Cloud Engineer ☁️&lt;/li&gt;
&lt;li&gt;DevOps Engineer ⚙️&lt;/li&gt;
&lt;li&gt;Security Engineer 🛡️&lt;/li&gt;
&lt;li&gt;Backend Developer 👨‍💻&lt;/li&gt;
&lt;li&gt;or preparing for AWS certifications 📚&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Understanding IAM is absolutely mandatory.&lt;/p&gt;

&lt;p&gt;And once IAM is understood, the next powerful step is using the &lt;strong&gt;AWS CLI&lt;/strong&gt; to interact with AWS directly from your terminal like a real cloud engineer.&lt;/p&gt;

&lt;p&gt;In this guide we'll cover:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;What IAM is&lt;/li&gt;
&lt;li&gt;IAM Users&lt;/li&gt;
&lt;li&gt;IAM Roles&lt;/li&gt;
&lt;li&gt;IAM Policies&lt;/li&gt;
&lt;li&gt;MFA (Multi-Factor Authentication)&lt;/li&gt;
&lt;li&gt;AWS CLI setup&lt;/li&gt;
&lt;li&gt;Real-world best practices&lt;/li&gt;
&lt;li&gt;Security mistakes beginners make&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🔗 Resources
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;GitHub Repo:&lt;/strong&gt;&lt;br&gt;
&lt;a href="https://github.com/17J/30-Days-Cloud-DevSecOps-Journey" rel="noopener noreferrer"&gt;https://github.com/17J/30-Days-Cloud-DevSecOps-Journey&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;AWS Command Sheet:&lt;/strong&gt;&lt;br&gt;
&lt;a href="https://aws-command.vercel.app/" rel="noopener noreferrer"&gt;https://aws-command.vercel.app/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  ☁️ What is IAM?
&lt;/h2&gt;

&lt;p&gt;IAM stands for:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Identity and Access Management&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;It is the AWS service used to control:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Authentication → &lt;em&gt;Who are you?&lt;/em&gt;
&lt;/li&gt;
&lt;li&gt;Authorization → &lt;em&gt;What can you do?&lt;/em&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Think of IAM as the &lt;strong&gt;security guard of AWS&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Without IAM, anyone could access:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;EC2 servers&lt;/li&gt;
&lt;li&gt;S3 buckets&lt;/li&gt;
&lt;li&gt;Databases&lt;/li&gt;
&lt;li&gt;Secrets&lt;/li&gt;
&lt;li&gt;Billing data&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And that would become a disaster very quickly.&lt;/p&gt;




&lt;h2&gt;
  
  
  🏢 Real-World Example
&lt;/h2&gt;

&lt;p&gt;Imagine a company has:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Developers&lt;/li&gt;
&lt;li&gt;DevOps Engineers&lt;/li&gt;
&lt;li&gt;Security Team&lt;/li&gt;
&lt;li&gt;Finance Team&lt;/li&gt;
&lt;li&gt;Interns&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Should everyone get full AWS admin access?&lt;/p&gt;

&lt;p&gt;❌ Absolutely not.&lt;/p&gt;

&lt;p&gt;Instead:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Team&lt;/th&gt;
&lt;th&gt;Access&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Developers&lt;/td&gt;
&lt;td&gt;EC2 + Logs&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;DevOps&lt;/td&gt;
&lt;td&gt;Infrastructure&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Finance&lt;/td&gt;
&lt;td&gt;Billing only&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Security&lt;/td&gt;
&lt;td&gt;Audit + Monitoring&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Interns&lt;/td&gt;
&lt;td&gt;Read-only&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;IAM makes this possible.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Core IAM Components
&lt;/h2&gt;

&lt;p&gt;AWS IAM mainly consists of:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fjw04997sy5uphgjdt4as.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fjw04997sy5uphgjdt4as.png" alt="Iam DashBoard" width="800" height="424"&gt;&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;IAM
├── Users
├── Groups
├── Roles
├── Policies
└── MFA
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  👤 IAM Users
&lt;/h2&gt;

&lt;p&gt;An IAM User represents a person or application that needs access to AWS.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6wvp5mll8xfentuun4nf.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6wvp5mll8xfentuun4nf.png" alt="Iam User" width="800" height="280"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Examples:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Rahul&lt;/li&gt;
&lt;li&gt;DevOps Engineer&lt;/li&gt;
&lt;li&gt;CI/CD Pipeline&lt;/li&gt;
&lt;li&gt;Jenkins Server&lt;/li&gt;
&lt;li&gt;Terraform Automation&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Each IAM user can have:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Password&lt;/li&gt;
&lt;li&gt;Access Keys&lt;/li&gt;
&lt;li&gt;Permissions&lt;/li&gt;
&lt;li&gt;MFA&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🔑 Types of IAM Access
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1️⃣ Console Access
&lt;/h3&gt;

&lt;p&gt;Used for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;AWS Web Dashboard login&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;https://aws.amazon.com/console/
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Uses:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Username&lt;/li&gt;
&lt;li&gt;Password&lt;/li&gt;
&lt;li&gt;MFA&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  2️⃣ Programmatic Access
&lt;/h3&gt;

&lt;p&gt;Used for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;AWS CLI&lt;/li&gt;
&lt;li&gt;SDKs&lt;/li&gt;
&lt;li&gt;Terraform&lt;/li&gt;
&lt;li&gt;CI/CD Pipelines&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Uses:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Access Key ID&lt;/li&gt;
&lt;li&gt;Secret Access Key&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;AWS_ACCESS_KEY_ID
AWS_SECRET_ACCESS_KEY
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ⚠️ Important Security Rule
&lt;/h2&gt;

&lt;p&gt;Never use the &lt;strong&gt;Root Account&lt;/strong&gt; for daily work.&lt;/p&gt;

&lt;p&gt;Root account has unlimited permissions.&lt;/p&gt;

&lt;p&gt;If compromised:&lt;/p&gt;

&lt;p&gt;💀 Entire AWS account can be destroyed.&lt;/p&gt;

&lt;p&gt;Instead:&lt;/p&gt;

&lt;p&gt;✅ Create IAM users.&lt;/p&gt;




&lt;h2&gt;
  
  
  👥 IAM Groups
&lt;/h2&gt;

&lt;p&gt;Groups help manage permissions more easily.&lt;/p&gt;

&lt;p&gt;Instead of assigning permissions individually:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F2s12le7olzfc51cgc6r2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F2s12le7olzfc51cgc6r2.png" alt="DevOps Group" width="800" height="208"&gt;&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Rahul → EC2 Access
Aman → EC2 Access
Riya → EC2 Access
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You create:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Developers Group → EC2 Access
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then add users to the group.&lt;/p&gt;

&lt;p&gt;Much cleaner.&lt;/p&gt;




&lt;h2&gt;
  
  
  🛡️ IAM Policies
&lt;/h2&gt;

&lt;p&gt;Policies define permissions.&lt;/p&gt;

&lt;p&gt;They are written in &lt;strong&gt;JSON&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Policies answer:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;What actions are allowed or denied?&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  📄 Example IAM Policy
&lt;/h2&gt;

&lt;p&gt;This policy gives read-only access to S3 buckets:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Feq5yybwmnb29823uf00w.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Feq5yybwmnb29823uf00w.png" alt="Policy" width="800" height="299"&gt;&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Understanding Policy Structure
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Component&lt;/th&gt;
&lt;th&gt;Meaning&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Effect&lt;/td&gt;
&lt;td&gt;Allow or Deny&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Action&lt;/td&gt;
&lt;td&gt;AWS API actions&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Resource&lt;/td&gt;
&lt;td&gt;Which resources&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Statement&lt;/td&gt;
&lt;td&gt;Permission block&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  🚫 Principle of Least Privilege
&lt;/h2&gt;

&lt;p&gt;One of the most important cloud security principles.&lt;/p&gt;

&lt;p&gt;Meaning:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Give only the permissions that are actually required.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Bad Example ❌&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="nl"&gt;"Action"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"*"&lt;/span&gt;&lt;span class="err"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="nl"&gt;"Resource"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"*"&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This gives full admin access.&lt;/p&gt;

&lt;p&gt;Good Example ✅&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="s2"&gt;"s3:GetObject"&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Only specific access.&lt;/p&gt;




&lt;h2&gt;
  
  
  🎭 IAM Roles
&lt;/h2&gt;

&lt;p&gt;Roles are extremely important in AWS.&lt;/p&gt;

&lt;p&gt;A Role is a temporary identity with permissions.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fcf07qz2xp3itvxmm76xn.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fcf07qz2xp3itvxmm76xn.png" alt="Iam Roles" width="800" height="280"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Unlike users:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Roles do NOT have passwords&lt;/li&gt;
&lt;li&gt;Roles do NOT have permanent access keys&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Instead:&lt;/p&gt;

&lt;p&gt;✅ AWS provides temporary credentials automatically.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Why Roles Matter
&lt;/h2&gt;

&lt;p&gt;Roles are heavily used for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;EC2 instances&lt;/li&gt;
&lt;li&gt;Lambda functions&lt;/li&gt;
&lt;li&gt;ECS containers&lt;/li&gt;
&lt;li&gt;Cross-account access&lt;/li&gt;
&lt;li&gt;Kubernetes workloads&lt;/li&gt;
&lt;li&gt;CI/CD systems&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🚀 Example: EC2 Accessing S3
&lt;/h2&gt;

&lt;p&gt;Suppose an EC2 server needs access to an S3 bucket.&lt;/p&gt;

&lt;p&gt;❌ Wrong Approach:&lt;/p&gt;

&lt;p&gt;Store AWS keys inside server files.&lt;/p&gt;

&lt;p&gt;Huge security risk.&lt;/p&gt;

&lt;p&gt;✅ Correct Approach:&lt;/p&gt;

&lt;p&gt;Attach an IAM Role to EC2.&lt;/p&gt;

&lt;p&gt;AWS automatically provides temporary credentials securely.&lt;/p&gt;




&lt;h2&gt;
  
  
  🔄 User vs Role
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;IAM User&lt;/th&gt;
&lt;th&gt;IAM Role&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Permanent identity&lt;/td&gt;
&lt;td&gt;Temporary identity&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Has password/access keys&lt;/td&gt;
&lt;td&gt;Temporary credentials&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Used by humans&lt;/td&gt;
&lt;td&gt;Used by services/apps&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Long-term access&lt;/td&gt;
&lt;td&gt;Short-term access&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  🔐 MFA (Multi-Factor Authentication)
&lt;/h2&gt;

&lt;p&gt;MFA adds an extra security layer.&lt;/p&gt;

&lt;p&gt;Instead of only:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Password
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You also need:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;OTP / Authenticator Code
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fe188hjkd2w04wupw3wmp.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fe188hjkd2w04wupw3wmp.png" alt="MFA First" width="800" height="446"&gt;&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  📱 Common MFA Methods
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;MFA Type&lt;/th&gt;
&lt;th&gt;Example&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Authenticator App&lt;/td&gt;
&lt;td&gt;Google Authenticator&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Hardware Key&lt;/td&gt;
&lt;td&gt;YubiKey&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;SMS&lt;/td&gt;
&lt;td&gt;OTP Messages&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  ⚠️ Why MFA is Critical
&lt;/h2&gt;

&lt;p&gt;Even if hackers steal passwords:&lt;/p&gt;

&lt;p&gt;✅ They still cannot login without MFA.&lt;/p&gt;

&lt;p&gt;AWS strongly recommends enabling MFA for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Root Account&lt;/li&gt;
&lt;li&gt;Admin Users&lt;/li&gt;
&lt;li&gt;Production Accounts&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🔥 Real Industry Fact
&lt;/h2&gt;

&lt;p&gt;Many cloud breaches happen because:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Access keys leaked&lt;/li&gt;
&lt;li&gt;No MFA enabled&lt;/li&gt;
&lt;li&gt;Over-permissioned IAM users&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Cloud security failures are often &lt;strong&gt;identity failures&lt;/strong&gt;.&lt;/p&gt;




&lt;h2&gt;
  
  
  💻 What is AWS CLI?
&lt;/h2&gt;

&lt;p&gt;AWS CLI stands for:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;AWS Command Line Interface&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;It allows you to manage AWS directly from the terminal.&lt;/p&gt;

&lt;p&gt;Instead of clicking in the console:&lt;/p&gt;

&lt;p&gt;You can automate everything:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;aws s3 &lt;span class="nb"&gt;ls&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🚀 Why AWS CLI is Powerful
&lt;/h2&gt;

&lt;p&gt;With CLI you can:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Automate infrastructure&lt;/li&gt;
&lt;li&gt;Create scripts&lt;/li&gt;
&lt;li&gt;Manage EC2&lt;/li&gt;
&lt;li&gt;Upload to S3&lt;/li&gt;
&lt;li&gt;Configure IAM&lt;/li&gt;
&lt;li&gt;Integrate CI/CD&lt;/li&gt;
&lt;li&gt;Manage Kubernetes&lt;/li&gt;
&lt;li&gt;Use Terraform pipelines&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Professional cloud engineers use CLI daily.&lt;/p&gt;




&lt;h3&gt;
  
  
  🛠️ Installing AWS CLI
&lt;/h3&gt;

&lt;h2&gt;
  
  
  🐧 Linux
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="s2"&gt;"https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip"&lt;/span&gt; &lt;span class="nt"&gt;-o&lt;/span&gt; &lt;span class="s2"&gt;"awscliv2.zip"&lt;/span&gt;

unzip awscliv2.zip

&lt;span class="nb"&gt;sudo&lt;/span&gt; ./aws/install
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🪟 Windows
&lt;/h2&gt;

&lt;p&gt;Download from:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://aws.amazon.com/cli/?utm_source=chatgpt.com" rel="noopener noreferrer"&gt;AWS CLI Official Installer&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  🍎 macOS
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;brew &lt;span class="nb"&gt;install &lt;/span&gt;awscli
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ✅ Verify Installation
&lt;/h2&gt;

&lt;p&gt;Run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;aws &lt;span class="nt"&gt;--version&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;aws-cli/2.27.0 Python/3.x
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ⚙️ Configure AWS CLI
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F5a93vmn4y69e4rhigw1u.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F5a93vmn4y69e4rhigw1u.png" alt="aws cli" width="800" height="150"&gt;&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  📁 AWS CLI Configuration Files
&lt;/h2&gt;

&lt;p&gt;AWS stores credentials here:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;~/.aws/credentials
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And config here:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;~/.aws/config
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ⚠️ Never Commit AWS Keys to GitHub
&lt;/h2&gt;

&lt;p&gt;One of the biggest beginner mistakes.&lt;/p&gt;

&lt;p&gt;If keys leak publicly:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Attackers can use your AWS account&lt;/li&gt;
&lt;li&gt;Crypto mining attacks happen&lt;/li&gt;
&lt;li&gt;Huge AWS bills occur&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Use:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;IAM Roles&lt;/li&gt;
&lt;li&gt;Secrets Managers&lt;/li&gt;
&lt;li&gt;Environment Variables&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Instead.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧪 Useful AWS CLI Commands
&lt;/h2&gt;

&lt;h3&gt;
  
  
  List S3 Buckets
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;aws s3 &lt;span class="nb"&gt;ls&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  List EC2 Instances
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;aws ec2 describe-instances
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  List IAM Users
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;aws iam list-users
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  Get Current Identity
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;aws sts get-caller-identity
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is extremely useful for debugging permissions.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 AWS STS (Security Token Service)
&lt;/h2&gt;

&lt;p&gt;STS provides temporary credentials.&lt;/p&gt;

&lt;p&gt;Used heavily with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;IAM Roles&lt;/li&gt;
&lt;li&gt;Federation&lt;/li&gt;
&lt;li&gt;Kubernetes IAM&lt;/li&gt;
&lt;li&gt;Cross-account access&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This is one of the most important concepts in enterprise AWS security.&lt;/p&gt;




&lt;h2&gt;
  
  
  🏢 Real Enterprise IAM Practices
&lt;/h2&gt;

&lt;p&gt;Large companies usually implement:&lt;/p&gt;

&lt;p&gt;✅ SSO (Single Sign-On)&lt;br&gt;
✅ MFA everywhere&lt;br&gt;
✅ Role-based access&lt;br&gt;
✅ Temporary credentials&lt;br&gt;
✅ Permission boundaries&lt;br&gt;
✅ IAM Access Analyzer&lt;br&gt;
✅ Audit logging with CloudTrail&lt;/p&gt;


&lt;h2&gt;
  
  
  🔥 Common IAM Mistakes
&lt;/h2&gt;
&lt;h2&gt;
  
  
  ❌ Using Root Account Daily
&lt;/h2&gt;

&lt;p&gt;Very dangerous.&lt;/p&gt;


&lt;h2&gt;
  
  
  ❌ Giving AdminAccess to Everyone
&lt;/h2&gt;

&lt;p&gt;Creates massive attack surface.&lt;/p&gt;


&lt;h2&gt;
  
  
  ❌ Hardcoding AWS Keys
&lt;/h2&gt;

&lt;p&gt;Common breach reason.&lt;/p&gt;


&lt;h2&gt;
  
  
  ❌ No MFA
&lt;/h2&gt;

&lt;p&gt;Huge security risk.&lt;/p&gt;


&lt;h2&gt;
  
  
  ❌ Overly Permissive Policies
&lt;/h2&gt;

&lt;p&gt;Avoid:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="nl"&gt;"Action"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"*"&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ☁️ IAM + DevOps + Security
&lt;/h2&gt;

&lt;p&gt;IAM connects with almost everything in AWS:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Service&lt;/th&gt;
&lt;th&gt;IAM Usage&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;EC2&lt;/td&gt;
&lt;td&gt;Instance Roles&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Lambda&lt;/td&gt;
&lt;td&gt;Execution Roles&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Kubernetes (EKS)&lt;/td&gt;
&lt;td&gt;IAM Service Accounts&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Terraform&lt;/td&gt;
&lt;td&gt;Automation Access&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;CI/CD&lt;/td&gt;
&lt;td&gt;Pipeline Permissions&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;CloudTrail&lt;/td&gt;
&lt;td&gt;Audit Logs&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;IAM is the backbone of AWS security.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Final Thoughts
&lt;/h2&gt;

&lt;p&gt;If networking is the foundation of cloud…&lt;/p&gt;

&lt;p&gt;Then IAM is the foundation of cloud security.&lt;/p&gt;

&lt;p&gt;Most real-world AWS problems are not caused by:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;EC2&lt;/li&gt;
&lt;li&gt;Kubernetes&lt;/li&gt;
&lt;li&gt;Lambda&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;They’re caused by:&lt;/p&gt;

&lt;p&gt;❌ Wrong permissions&lt;br&gt;
❌ Exposed credentials&lt;br&gt;
❌ Weak access control&lt;/p&gt;

&lt;p&gt;Mastering IAM early will make you a much stronger:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Cloud Engineer&lt;/li&gt;
&lt;li&gt;DevOps Engineer&lt;/li&gt;
&lt;li&gt;Security Engineer&lt;/li&gt;
&lt;li&gt;Platform Engineer&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And AWS CLI will help you automate everything professionally.&lt;/p&gt;

</description>
      <category>masterclassdevsecops</category>
      <category>aws</category>
      <category>webdev</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>Day 7 — Cloud Computing &amp; AWS Fundamentals</title>
      <dc:creator>Rahul Joshi</dc:creator>
      <pubDate>Mon, 18 May 2026 05:53:08 +0000</pubDate>
      <link>https://forem.com/17j/day-7-cloud-computing-aws-fundamentals-24f2</link>
      <guid>https://forem.com/17j/day-7-cloud-computing-aws-fundamentals-24f2</guid>
      <description>&lt;p&gt;Cloud computing is no longer optional.&lt;/p&gt;

&lt;p&gt;Whether you're building modern applications, deploying containers, running AI workloads, hosting websites, automating DevOps pipelines, or scaling startups — cloud platforms power almost everything today.&lt;/p&gt;

&lt;p&gt;If you're entering:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;DevOps&lt;/li&gt;
&lt;li&gt;Cloud Engineering&lt;/li&gt;
&lt;li&gt;Cybersecurity&lt;/li&gt;
&lt;li&gt;Backend Development&lt;/li&gt;
&lt;li&gt;Platform Engineering&lt;/li&gt;
&lt;li&gt;AI Infrastructure&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;then understanding cloud fundamentals is one of the best investments you can make.&lt;/p&gt;

&lt;p&gt;Let’s start from the foundation.&lt;/p&gt;

&lt;h2&gt;
  
  
  🔗 Resources
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;GitHub Repo:&lt;/strong&gt;
&lt;a href="https://github.com/17J/30-Days-Cloud-DevSecOps-Journey" rel="noopener noreferrer"&gt;https://github.com/17J/30-Days-Cloud-DevSecOps-Journey&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🌍 What is Cloud Computing?
&lt;/h2&gt;

&lt;p&gt;Cloud computing means using computing resources over the internet instead of managing physical infrastructure yourself.&lt;/p&gt;

&lt;p&gt;Instead of buying:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;physical servers&lt;/li&gt;
&lt;li&gt;networking hardware&lt;/li&gt;
&lt;li&gt;storage devices&lt;/li&gt;
&lt;li&gt;cooling systems&lt;/li&gt;
&lt;li&gt;data center space&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;you rent resources from cloud providers on-demand.&lt;/p&gt;

&lt;p&gt;Think of cloud like electricity.&lt;/p&gt;

&lt;p&gt;You don’t build a power plant to use electricity.&lt;/p&gt;

&lt;p&gt;Similarly, you don’t need to build a data center to run applications anymore.&lt;/p&gt;




&lt;h2&gt;
  
  
  ⚡ Why Cloud Computing Became So Popular
&lt;/h2&gt;

&lt;p&gt;Traditional infrastructure had many problems:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;High upfront costs&lt;/li&gt;
&lt;li&gt;Scaling issues&lt;/li&gt;
&lt;li&gt;Slow provisioning&lt;/li&gt;
&lt;li&gt;Hardware maintenance&lt;/li&gt;
&lt;li&gt;Downtime risks&lt;/li&gt;
&lt;li&gt;Complex disaster recovery&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Cloud solved this by introducing:&lt;/p&gt;

&lt;p&gt;✅ Pay-as-you-go pricing&lt;br&gt;
✅ Global scalability&lt;br&gt;
✅ High availability&lt;br&gt;
✅ Fast deployments&lt;br&gt;
✅ Managed services&lt;br&gt;
✅ Built-in security tooling&lt;br&gt;
✅ Infrastructure automation&lt;/p&gt;

&lt;p&gt;This completely changed how software is built and deployed.&lt;/p&gt;


&lt;h2&gt;
  
  
  🧠 Core Cloud Computing Service Model
&lt;/h2&gt;

&lt;p&gt;Before jumping into AWS, understand these important Service Models.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F93q0h2hc25pb8m6yh1yn.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F93q0h2hc25pb8m6yh1yn.png" alt="Pass SaaS " width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;


&lt;h2&gt;
  
  
  🖥 Infrastructure as a Service (IaaS)
&lt;/h2&gt;

&lt;p&gt;You rent infrastructure components like:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;virtual machines&lt;/li&gt;
&lt;li&gt;networking&lt;/li&gt;
&lt;li&gt;storage&lt;/li&gt;
&lt;li&gt;load balancers&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Example:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Amazon EC2&lt;/li&gt;
&lt;li&gt;Azure Virtual Machines&lt;/li&gt;
&lt;li&gt;Google Compute Engine&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;You manage:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;OS&lt;/li&gt;
&lt;li&gt;applications&lt;/li&gt;
&lt;li&gt;runtime&lt;/li&gt;
&lt;li&gt;security patches&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Cloud provider manages:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;hardware&lt;/li&gt;
&lt;li&gt;networking&lt;/li&gt;
&lt;li&gt;physical security&lt;/li&gt;
&lt;/ul&gt;


&lt;h2&gt;
  
  
  ⚙️ Platform as a Service (PaaS)
&lt;/h2&gt;

&lt;p&gt;The cloud provider manages the infrastructure and runtime.&lt;/p&gt;

&lt;p&gt;You focus only on your application code.&lt;/p&gt;

&lt;p&gt;Examples:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;AWS Elastic Beanstalk&lt;/li&gt;
&lt;li&gt;Azure App Service&lt;/li&gt;
&lt;li&gt;Google App Engine&lt;/li&gt;
&lt;/ul&gt;


&lt;h2&gt;
  
  
  🚀 Software as a Service (SaaS)
&lt;/h2&gt;

&lt;p&gt;Fully managed software delivered over the internet.&lt;/p&gt;

&lt;p&gt;Examples:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Gmail&lt;/li&gt;
&lt;li&gt;Slack&lt;/li&gt;
&lt;li&gt;Zoom&lt;/li&gt;
&lt;li&gt;Microsoft 365&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;You simply use the software.&lt;/p&gt;

&lt;p&gt;No infrastructure management needed.&lt;/p&gt;


&lt;h2&gt;
  
  
  ☁️ Types of Cloud Computing
&lt;/h2&gt;


&lt;h3&gt;
  
  
  🌐 Public Cloud
&lt;/h3&gt;

&lt;p&gt;Public cloud means infrastructure is owned and managed by cloud providers.&lt;/p&gt;

&lt;p&gt;Examples:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Amazon Web Services (AWS)&lt;/li&gt;
&lt;li&gt;Microsoft Azure&lt;/li&gt;
&lt;li&gt;Google Cloud Platform (GCP)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;You share underlying infrastructure with other customers but your workloads remain logically isolated.&lt;/p&gt;
&lt;h3&gt;
  
  
  Advantages
&lt;/h3&gt;

&lt;p&gt;✅ Cost effective&lt;br&gt;
✅ Highly scalable&lt;br&gt;
✅ Global infrastructure&lt;br&gt;
✅ Massive service ecosystem&lt;br&gt;
✅ Fast deployment&lt;/p&gt;
&lt;h3&gt;
  
  
  Best For
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Startups&lt;/li&gt;
&lt;li&gt;Modern applications&lt;/li&gt;
&lt;li&gt;SaaS platforms&lt;/li&gt;
&lt;li&gt;DevOps environments&lt;/li&gt;
&lt;li&gt;AI workloads&lt;/li&gt;
&lt;/ul&gt;


&lt;h3&gt;
  
  
  🏢 Private Cloud
&lt;/h3&gt;

&lt;p&gt;Private cloud is dedicated infrastructure used by a single organization.&lt;/p&gt;

&lt;p&gt;It can be hosted:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;on-premises&lt;/li&gt;
&lt;li&gt;in private data centers&lt;/li&gt;
&lt;li&gt;through dedicated cloud setups&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;
  
  
  Advantages
&lt;/h3&gt;

&lt;p&gt;✅ More control&lt;br&gt;
✅ Custom security policies&lt;br&gt;
✅ Regulatory compliance&lt;br&gt;
✅ Better for sensitive workloads&lt;/p&gt;
&lt;h3&gt;
  
  
  Best For
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Banks&lt;/li&gt;
&lt;li&gt;Government systems&lt;/li&gt;
&lt;li&gt;Healthcare organizations&lt;/li&gt;
&lt;li&gt;Large enterprises&lt;/li&gt;
&lt;/ul&gt;


&lt;h3&gt;
  
  
  🔀 Hybrid Cloud
&lt;/h3&gt;

&lt;p&gt;Hybrid cloud combines:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;public cloud&lt;/li&gt;
&lt;li&gt;private cloud&lt;/li&gt;
&lt;li&gt;on-premises infrastructure&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Organizations keep sensitive systems private while scaling workloads in public cloud.&lt;/p&gt;

&lt;p&gt;This is extremely common in enterprises today.&lt;/p&gt;


&lt;h2&gt;
  
  
  📊 Cloud Providers in Market
&lt;/h2&gt;

&lt;p&gt;The cloud industry is dominated by three major players:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fztn6pt6g31kvxs13zezc.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fztn6pt6g31kvxs13zezc.png" alt="Cloud Provider Types" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Together, these providers control nearly 70% of the global cloud market.&lt;/p&gt;


&lt;h2&gt;
  
  
  🥇 Amazon Web Services (AWS)
&lt;/h2&gt;

&lt;p&gt;Amazon Web Services remains the market leader in 2026.&lt;/p&gt;

&lt;p&gt;Why?&lt;/p&gt;

&lt;p&gt;Because AWS offers:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;200+ cloud services&lt;/li&gt;
&lt;li&gt;massive global infrastructure&lt;/li&gt;
&lt;li&gt;mature ecosystem&lt;/li&gt;
&lt;li&gt;strongest community support&lt;/li&gt;
&lt;li&gt;enterprise adoption&lt;/li&gt;
&lt;li&gt;startup friendliness&lt;/li&gt;
&lt;li&gt;powerful DevOps integrations&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;AWS also dominates cloud-related job postings globally. ([CloudPros][1])&lt;/p&gt;


&lt;h2&gt;
  
  
  🔵 Microsoft Azure
&lt;/h2&gt;

&lt;p&gt;Microsoft Azure is extremely strong in enterprise environments.&lt;/p&gt;

&lt;p&gt;Its biggest strengths are:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Microsoft ecosystem integration&lt;/li&gt;
&lt;li&gt;Active Directory&lt;/li&gt;
&lt;li&gt;Office 365 integration&lt;/li&gt;
&lt;li&gt;enterprise compliance&lt;/li&gt;
&lt;li&gt;hybrid cloud support&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Large corporations heavily prefer Azure.&lt;/p&gt;


&lt;h2&gt;
  
  
  🔴 Google Cloud Platform (GCP)
&lt;/h2&gt;

&lt;p&gt;Google Cloud Platform is famous for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Kubernetes leadership&lt;/li&gt;
&lt;li&gt;BigQuery&lt;/li&gt;
&lt;li&gt;AI/ML tooling&lt;/li&gt;
&lt;li&gt;data engineering&lt;/li&gt;
&lt;li&gt;global networking&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Many AI-first companies choose GCP because of its data and machine learning ecosystem. ([Reddit][2])&lt;/p&gt;


&lt;h2&gt;
  
  
  🚀 Why Beginners Usually Start with AWS
&lt;/h2&gt;

&lt;p&gt;Most beginners start with AWS because:&lt;/p&gt;

&lt;p&gt;✅ Largest job market&lt;br&gt;
✅ Massive learning resources&lt;br&gt;
✅ Huge community&lt;br&gt;
✅ Strong free tier&lt;br&gt;
✅ Broadest service coverage&lt;br&gt;
✅ Industry-standard cloud concepts&lt;/p&gt;

&lt;p&gt;Learning AWS fundamentals also makes learning Azure and GCP easier later.&lt;/p&gt;


&lt;h2&gt;
  
  
  🧾 AWS Prerequisites Before Learning
&lt;/h2&gt;

&lt;p&gt;Before starting AWS seriously, you should have:&lt;/p&gt;


&lt;h2&gt;
  
  
  💻 Basic Linux Knowledge
&lt;/h2&gt;

&lt;p&gt;Understand:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;file systems&lt;/li&gt;
&lt;li&gt;permissions&lt;/li&gt;
&lt;li&gt;package management&lt;/li&gt;
&lt;li&gt;shell commands&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Important commands:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;ls
cd
mkdir
rm
chmod
chown
grep
cat&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🌐 Basic Networking Concepts
&lt;/h2&gt;

&lt;p&gt;You should know:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;IP addresses&lt;/li&gt;
&lt;li&gt;DNS&lt;/li&gt;
&lt;li&gt;HTTP/HTTPS&lt;/li&gt;
&lt;li&gt;ports&lt;/li&gt;
&lt;li&gt;firewalls&lt;/li&gt;
&lt;li&gt;routing&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These concepts become critical in cloud networking.&lt;/p&gt;




&lt;h2&gt;
  
  
  🔐 Basic Security Understanding
&lt;/h2&gt;

&lt;p&gt;Learn:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;IAM basics&lt;/li&gt;
&lt;li&gt;authentication&lt;/li&gt;
&lt;li&gt;authorization&lt;/li&gt;
&lt;li&gt;SSH keys&lt;/li&gt;
&lt;li&gt;least privilege principle&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Cloud security is one of the most important skills today.&lt;/p&gt;




&lt;h2&gt;
  
  
  🐳 Optional but Helpful
&lt;/h2&gt;

&lt;p&gt;These are not mandatory but highly useful:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Git &amp;amp; GitHub&lt;/li&gt;
&lt;li&gt;Docker&lt;/li&gt;
&lt;li&gt;CI/CD basics&lt;/li&gt;
&lt;li&gt;Kubernetes basics&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  🪪 Step 1: Create an AWS Account
&lt;/h3&gt;

&lt;p&gt;To start learning AWS:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fu3qqq2uzxlv3yavchlrc.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fu3qqq2uzxlv3yavchlrc.png" alt="AWS Sign Up Page" width="800" height="511"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Go to AWS official website&lt;/li&gt;
&lt;li&gt;Create a free-tier account&lt;/li&gt;
&lt;li&gt;Add billing information&lt;/li&gt;
&lt;li&gt;Enable MFA (Multi-Factor Authentication)&lt;/li&gt;
&lt;li&gt;Create an IAM user instead of using root account daily&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Using the root account regularly is considered bad practice.&lt;/p&gt;




&lt;h3&gt;
  
  
  🌍 AWS Regions &amp;amp; Availability Zones
&lt;/h3&gt;

&lt;p&gt;This is one of the MOST important AWS concepts.&lt;/p&gt;




&lt;h3&gt;
  
  
  📍 AWS Region
&lt;/h3&gt;

&lt;p&gt;A Region is a geographical location where AWS has data centers.&lt;/p&gt;

&lt;p&gt;Examples:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;us-east-1&lt;/li&gt;
&lt;li&gt;ap-south-1&lt;/li&gt;
&lt;li&gt;eu-west-1&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Each region is isolated from others.&lt;/p&gt;




&lt;h3&gt;
  
  
  🏢 Availability Zone (AZ)
&lt;/h3&gt;

&lt;p&gt;An Availability Zone is one or more physically separate data centers inside a region.&lt;/p&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Region: ap-south-1 (Mumbai)

AZs:
- ap-south-1a
- ap-south-1b
- ap-south-1c
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Applications are deployed across multiple AZs for:&lt;/p&gt;

&lt;p&gt;✅ High availability&lt;br&gt;
✅ Fault tolerance&lt;br&gt;
✅ Disaster recovery&lt;/p&gt;


&lt;h3&gt;
  
  
  🧠 Easy Analogy
&lt;/h3&gt;

&lt;p&gt;Think of it like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Country → State → Buildings

Region → Availability Zones → Data Centers
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ⚙️ Core AWS Services Every Beginner Should Learn
&lt;/h2&gt;




&lt;h3&gt;
  
  
  🖥 Amazon EC2 (Elastic Compute Cloud)
&lt;/h3&gt;

&lt;p&gt;Virtual machines in AWS.&lt;/p&gt;

&lt;p&gt;Used for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;hosting applications&lt;/li&gt;
&lt;li&gt;web servers&lt;/li&gt;
&lt;li&gt;backend APIs&lt;/li&gt;
&lt;li&gt;databases&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;EC2 is foundational AWS knowledge.&lt;/p&gt;




&lt;h3&gt;
  
  
  🪣 Amazon S3 (Simple Storage Service)
&lt;/h3&gt;

&lt;p&gt;Object storage service.&lt;/p&gt;

&lt;p&gt;Used for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;backups&lt;/li&gt;
&lt;li&gt;static websites&lt;/li&gt;
&lt;li&gt;media storage&lt;/li&gt;
&lt;li&gt;logs&lt;/li&gt;
&lt;li&gt;data lakes&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;S3 is one of the most widely used AWS services.&lt;/p&gt;




&lt;h3&gt;
  
  
  🌐 Amazon VPC (Virtual Private Cloud)
&lt;/h3&gt;

&lt;p&gt;Allows you to create isolated cloud networks.&lt;/p&gt;

&lt;p&gt;You control:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;subnets&lt;/li&gt;
&lt;li&gt;routing tables&lt;/li&gt;
&lt;li&gt;firewalls&lt;/li&gt;
&lt;li&gt;internet access&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This is where networking becomes important.&lt;/p&gt;




&lt;h3&gt;
  
  
  🔐 IAM (Identity and Access Management)
&lt;/h3&gt;

&lt;p&gt;Controls permissions in AWS.&lt;/p&gt;

&lt;p&gt;You manage:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;users&lt;/li&gt;
&lt;li&gt;roles&lt;/li&gt;
&lt;li&gt;groups&lt;/li&gt;
&lt;li&gt;policies&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;IAM is the heart of AWS security.&lt;/p&gt;




&lt;h3&gt;
  
  
  ⚖️ Elastic Load Balancer (ELB)
&lt;/h3&gt;

&lt;p&gt;Distributes traffic across multiple servers.&lt;/p&gt;

&lt;p&gt;Benefits:&lt;/p&gt;

&lt;p&gt;✅ High availability&lt;br&gt;
✅ Scalability&lt;br&gt;
✅ Better fault tolerance&lt;/p&gt;




&lt;h3&gt;
  
  
  📈 Auto Scaling
&lt;/h3&gt;

&lt;p&gt;Automatically increases or decreases infrastructure based on traffic.&lt;/p&gt;

&lt;p&gt;This is one of cloud computing’s biggest advantages.&lt;/p&gt;




&lt;h3&gt;
  
  
  🗄 Amazon RDS
&lt;/h3&gt;

&lt;p&gt;Managed relational database service.&lt;/p&gt;

&lt;p&gt;Supports:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;MySQL&lt;/li&gt;
&lt;li&gt;PostgreSQL&lt;/li&gt;
&lt;li&gt;MariaDB&lt;/li&gt;
&lt;li&gt;SQL Server&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;AWS handles backups, patching, and maintenance.&lt;/p&gt;




&lt;h3&gt;
  
  
  🧱 CloudFormation
&lt;/h3&gt;

&lt;p&gt;Infrastructure as Code (IaC) service.&lt;/p&gt;

&lt;p&gt;You define infrastructure using templates.&lt;/p&gt;

&lt;p&gt;Modern cloud engineering heavily depends on automation.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Cloud Formation Templates&lt;/li&gt;
&lt;li&gt;Terraform&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🔐 AWS Shared Responsibilty Model:
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fz7e301xumvzxcuw9kjr5.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fz7e301xumvzxcuw9kjr5.png" alt="Shared Responsbility Model" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This concept is VERY important.&lt;/p&gt;

&lt;p&gt;Many beginners misunderstand cloud security.&lt;/p&gt;




&lt;h3&gt;
  
  
  🤝 What AWS Handles
&lt;/h3&gt;

&lt;p&gt;AWS is responsible for:&lt;/p&gt;

&lt;p&gt;✅ Physical servers&lt;br&gt;
✅ Data centers&lt;br&gt;
✅ Networking hardware&lt;br&gt;
✅ Hypervisors&lt;br&gt;
✅ Physical security&lt;/p&gt;




&lt;h3&gt;
  
  
  👨‍💻 What YOU Handle
&lt;/h3&gt;

&lt;p&gt;You are responsible for:&lt;/p&gt;

&lt;p&gt;✅ IAM permissions&lt;br&gt;
✅ Application security&lt;br&gt;
✅ OS patching (EC2)&lt;br&gt;
✅ Data encryption&lt;br&gt;
✅ Security groups&lt;br&gt;
✅ Network configuration&lt;/p&gt;




&lt;h3&gt;
  
  
  🧠 Simple Rule
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Security OF the cloud → AWS
Security IN the cloud → You
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is the core idea behind the shared responsibility model.&lt;/p&gt;




&lt;h3&gt;
  
  
  🎯 Final Thoughts
&lt;/h3&gt;

&lt;p&gt;Cloud computing is now the backbone of modern technology.&lt;/p&gt;

&lt;p&gt;Every major industry today relies on cloud platforms for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;scalability&lt;/li&gt;
&lt;li&gt;automation&lt;/li&gt;
&lt;li&gt;security&lt;/li&gt;
&lt;li&gt;AI workloads&lt;/li&gt;
&lt;li&gt;application hosting&lt;/li&gt;
&lt;li&gt;global infrastructure&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you're serious about DevOps, backend engineering, cybersecurity, platform engineering, or modern software development — cloud fundamentals are non-negotiable.&lt;/p&gt;

&lt;p&gt;Start small.&lt;/p&gt;

&lt;p&gt;Learn the basics deeply.&lt;/p&gt;

&lt;p&gt;Understand networking.&lt;/p&gt;

&lt;p&gt;Understand security.&lt;/p&gt;

&lt;p&gt;Then build projects consistently.&lt;/p&gt;

&lt;p&gt;Because in 2026, cloud knowledge is no longer a bonus skill.&lt;/p&gt;

&lt;p&gt;It’s a core engineering skill.&lt;/p&gt;

</description>
      <category>masterclassdevsecops</category>
      <category>webdev</category>
      <category>productivity</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>Day 6 — Docker &amp; Containerization</title>
      <dc:creator>Rahul Joshi</dc:creator>
      <pubDate>Sun, 17 May 2026 10:46:14 +0000</pubDate>
      <link>https://forem.com/17j/day-6-docker-containerization-3cdb</link>
      <guid>https://forem.com/17j/day-6-docker-containerization-3cdb</guid>
      <description>&lt;p&gt;Modern software development has changed completely.&lt;/p&gt;

&lt;p&gt;Applications are no longer deployed directly on servers like before.&lt;/p&gt;

&lt;p&gt;Today, companies package applications into &lt;strong&gt;containers&lt;/strong&gt; so they can run consistently anywhere:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Developer laptop&lt;/li&gt;
&lt;li&gt;Cloud servers&lt;/li&gt;
&lt;li&gt;Kubernetes clusters&lt;/li&gt;
&lt;li&gt;CI/CD pipelines&lt;/li&gt;
&lt;li&gt;Edge infrastructure&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  🔗 Resources
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;GitHub Repo:&lt;/strong&gt;&lt;br&gt;
&lt;a href="https://github.com/17J/30-Days-Cloud-DevSecOps-Journey" rel="noopener noreferrer"&gt;https://github.com/17J/30-Days-Cloud-DevSecOps-Journey&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Docker Command Sheet:&lt;/strong&gt;&lt;br&gt;
&lt;a href="https://docker-command.vercel.app/" rel="noopener noreferrer"&gt;https://docker-command.vercel.app/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🧠 What is a Container?
&lt;/h2&gt;

&lt;p&gt;A container is a lightweight isolated environment that includes:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Application code&lt;/li&gt;
&lt;li&gt;Runtime&lt;/li&gt;
&lt;li&gt;Libraries&lt;/li&gt;
&lt;li&gt;Dependencies&lt;/li&gt;
&lt;li&gt;Environment variables&lt;/li&gt;
&lt;li&gt;System tools&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Everything required to run the application is packaged together.&lt;/p&gt;

&lt;p&gt;That means:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Same behavior everywhere&lt;/li&gt;
&lt;li&gt;Faster deployments&lt;/li&gt;
&lt;li&gt;Portable infrastructure&lt;/li&gt;
&lt;li&gt;Easy scaling&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  ⚔️ Containers vs Virtual Machines
&lt;/h2&gt;

&lt;p&gt;This is one of the most important concepts in DevOps.&lt;/p&gt;

&lt;p&gt;Both Containers and VMs isolate applications — but in very different ways.&lt;/p&gt;




&lt;h2&gt;
  
  
  🖥️ Virtual Machines (VMs)
&lt;/h2&gt;

&lt;p&gt;A VM includes:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Full Operating System&lt;/li&gt;
&lt;li&gt;Guest Kernel&lt;/li&gt;
&lt;li&gt;Hypervisor&lt;/li&gt;
&lt;li&gt;Application&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Problems with VMs
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;High memory usage&lt;/li&gt;
&lt;li&gt;Slow startup time&lt;/li&gt;
&lt;li&gt;Large storage consumption&lt;/li&gt;
&lt;li&gt;Less efficient scaling&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🐳 Containers
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F06gtggno8y76scmgmdzl.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F06gtggno8y76scmgmdzl.png" alt="Container " width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Containers share the host OS kernel.&lt;/p&gt;

&lt;p&gt;They only package:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Application&lt;/li&gt;
&lt;li&gt;Dependencies&lt;/li&gt;
&lt;li&gt;Runtime&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This makes them:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Lightweight&lt;/li&gt;
&lt;li&gt;Fast&lt;/li&gt;
&lt;li&gt;Portable&lt;/li&gt;
&lt;li&gt;Efficient&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  📊 Containers vs VMs Comparison
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Feature&lt;/th&gt;
&lt;th&gt;Containers&lt;/th&gt;
&lt;th&gt;Virtual Machines&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Startup Time&lt;/td&gt;
&lt;td&gt;Seconds&lt;/td&gt;
&lt;td&gt;Minutes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Size&lt;/td&gt;
&lt;td&gt;MBs&lt;/td&gt;
&lt;td&gt;GBs&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Performance&lt;/td&gt;
&lt;td&gt;Near-native&lt;/td&gt;
&lt;td&gt;Heavy overhead&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Isolation&lt;/td&gt;
&lt;td&gt;Process-level&lt;/td&gt;
&lt;td&gt;Full OS-level&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Resource Usage&lt;/td&gt;
&lt;td&gt;Low&lt;/td&gt;
&lt;td&gt;High&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Portability&lt;/td&gt;
&lt;td&gt;Excellent&lt;/td&gt;
&lt;td&gt;Moderate&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  📦 What is Docker?
&lt;/h2&gt;

&lt;p&gt;Docker is a platform used to:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Build applications&lt;/li&gt;
&lt;li&gt;Package applications&lt;/li&gt;
&lt;li&gt;Ship applications&lt;/li&gt;
&lt;li&gt;Run applications in isolated environments called &lt;strong&gt;containers&lt;/strong&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Docker ensures:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“It works the same everywhere.”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;This solves the classic developer problem:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“It works on my machine.”&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  🏗️ Docker Architecture
&lt;/h2&gt;

&lt;p&gt;Docker mainly consists of 3 components:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F4sv8qwyu0qp1nzy80id3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F4sv8qwyu0qp1nzy80id3.png" alt="Docker Registry" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  1️⃣ Docker Client
&lt;/h2&gt;

&lt;p&gt;The CLI where commands are executed.&lt;/p&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker build
docker run
docker ps
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  2️⃣ Docker Daemon
&lt;/h2&gt;

&lt;p&gt;The background service (&lt;code&gt;dockerd&lt;/code&gt;) responsible for managing:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Containers&lt;/li&gt;
&lt;li&gt;Images&lt;/li&gt;
&lt;li&gt;Networks&lt;/li&gt;
&lt;li&gt;Volumes&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  3️⃣ Docker Registry
&lt;/h2&gt;

&lt;p&gt;A place where Docker images are stored.&lt;/p&gt;

&lt;p&gt;Popular registries include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Docker Hub&lt;/li&gt;
&lt;li&gt;GitHub Container Registry&lt;/li&gt;
&lt;li&gt;AWS ECR&lt;/li&gt;
&lt;li&gt;Google Artifact Registry&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🧱 What is a Docker Image?
&lt;/h2&gt;

&lt;p&gt;A Docker Image is a:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Read-only blueprint used to create containers.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;It contains:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Application code&lt;/li&gt;
&lt;li&gt;Dependencies&lt;/li&gt;
&lt;li&gt;Runtime&lt;/li&gt;
&lt;li&gt;Configuration&lt;/li&gt;
&lt;li&gt;Libraries&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🧠 Simple Analogy
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Concept&lt;/th&gt;
&lt;th&gt;Real World Example&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Docker Image&lt;/td&gt;
&lt;td&gt;Recipe&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Docker Container&lt;/td&gt;
&lt;td&gt;Cooked Food&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The image is the template.&lt;/p&gt;

&lt;p&gt;The container is the running instance.&lt;/p&gt;




&lt;h2&gt;
  
  
  🔍 Popular Docker Images
&lt;/h2&gt;

&lt;p&gt;Some commonly used images:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;nginx
ubuntu
node
python
mysql
redis
postgres
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Pull an image:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker pull nginx
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Run a container:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker run nginx
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  📝 What is a Dockerfile?
&lt;/h2&gt;

&lt;p&gt;A &lt;code&gt;Dockerfile&lt;/code&gt; is a text file containing instructions used to build a Docker image.&lt;/p&gt;

&lt;p&gt;This is where containerization begins.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧱 Example Dockerfile
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="s"&gt; node:20-alpine&lt;/span&gt;

&lt;span class="k"&gt;WORKDIR&lt;/span&gt;&lt;span class="s"&gt; /app&lt;/span&gt;

&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; package.json package-lock.json ./&lt;/span&gt;

&lt;span class="k"&gt;RUN &lt;/span&gt;npm ci &lt;span class="nt"&gt;--only&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;production

&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; . .&lt;/span&gt;

&lt;span class="k"&gt;EXPOSE&lt;/span&gt;&lt;span class="s"&gt; 3000&lt;/span&gt;

&lt;span class="k"&gt;CMD&lt;/span&gt;&lt;span class="s"&gt; ["node", "app.js"]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🔬 Dockerfile Explained
&lt;/h2&gt;




&lt;h2&gt;
  
  
  &lt;code&gt;FROM&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;Defines the base image.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="s"&gt; node:20-alpine&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  &lt;code&gt;WORKDIR&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;Sets the working directory inside the container.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;WORKDIR&lt;/span&gt;&lt;span class="s"&gt; /app&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  &lt;code&gt;COPY&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;Copies files from local system into the container.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; . .&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  &lt;code&gt;RUN&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;Executes commands during image build.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;RUN &lt;/span&gt;npm &lt;span class="nb"&gt;install&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  &lt;code&gt;EXPOSE&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;Documents which port the application uses.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;EXPOSE&lt;/span&gt;&lt;span class="s"&gt; 3000&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  &lt;code&gt;CMD&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;Defines the default startup command.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;CMD&lt;/span&gt;&lt;span class="s"&gt; ["node", "app.js"]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🚀 Building Docker Images
&lt;/h2&gt;

&lt;p&gt;Build image:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker build &lt;span class="nt"&gt;-t&lt;/span&gt; myapp &lt;span class="nb"&gt;.&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Explanation
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Part&lt;/th&gt;
&lt;th&gt;Meaning&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;docker build&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Build Docker image&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;-t&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Tag image&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;myapp&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Image name&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;.&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Current directory&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  ▶️ Running Containers
&lt;/h2&gt;

&lt;p&gt;Run container:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker run &lt;span class="nt"&gt;-p&lt;/span&gt; 3000:3000 myapp
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🔍 Understanding Port Mapping
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nt"&gt;-p&lt;/span&gt; 3000:3000
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Means:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Host Machine&lt;/th&gt;
&lt;th&gt;Container&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;3000&lt;/td&gt;
&lt;td&gt;3000&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Access app on:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;http://localhost:3000
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  📂 Containerizing a Node.js Application
&lt;/h2&gt;




&lt;h2&gt;
  
  
  📁 Project Structure
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;project/
│
├── app.js
├── package.json
└── Dockerfile
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  📄 app.js
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;express&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;require&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;express&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;app&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;express&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;

&lt;span class="nx"&gt;app&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;req&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;res&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nx"&gt;res&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;send&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Docker is working!&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;

&lt;span class="nx"&gt;app&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;listen&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;3000&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  📄 package.json
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"dependencies"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"express"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"^4.18.2"&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  📄 Dockerfile
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="s"&gt; node:20-alpine&lt;/span&gt;

&lt;span class="k"&gt;WORKDIR&lt;/span&gt;&lt;span class="s"&gt; /app&lt;/span&gt;

&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; package*.json ./&lt;/span&gt;

&lt;span class="k"&gt;RUN &lt;/span&gt;npm ci

&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; . .&lt;/span&gt;

&lt;span class="k"&gt;EXPOSE&lt;/span&gt;&lt;span class="s"&gt; 3000&lt;/span&gt;

&lt;span class="k"&gt;CMD&lt;/span&gt;&lt;span class="s"&gt; ["node", "app.js"]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🏗️ Build the Image
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker build &lt;span class="nt"&gt;-t&lt;/span&gt; node-docker-demo &lt;span class="nb"&gt;.&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ▶️ Run the Container
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker run &lt;span class="nt"&gt;-p&lt;/span&gt; 3000:3000 node-docker-demo
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now open:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;http://localhost:3000
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You should see:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Docker is working!
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  📦 Docker Image Layers
&lt;/h2&gt;

&lt;p&gt;Docker images are layered.&lt;/p&gt;

&lt;p&gt;Each instruction creates a new layer.&lt;/p&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="s"&gt; ubuntu:24.04&lt;/span&gt;
&lt;span class="k"&gt;RUN &lt;/span&gt;apt update
&lt;span class="k"&gt;RUN &lt;/span&gt;apt &lt;span class="nb"&gt;install &lt;/span&gt;nginx
&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; . .&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Each line becomes a cached layer.&lt;/p&gt;

&lt;p&gt;This makes builds:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Faster&lt;/li&gt;
&lt;li&gt;Efficient&lt;/li&gt;
&lt;li&gt;Reusable&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  ⚡ Docker Caching
&lt;/h2&gt;

&lt;p&gt;Docker rebuilds only changed layers.&lt;/p&gt;

&lt;p&gt;That’s why Dockerfiles should be optimized carefully.&lt;/p&gt;




&lt;h2&gt;
  
  
  ✅ Cache-Friendly Pattern
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; package.json .&lt;/span&gt;
&lt;span class="k"&gt;RUN &lt;/span&gt;npm &lt;span class="nb"&gt;install&lt;/span&gt;

&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; . .&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Why?
&lt;/h3&gt;

&lt;p&gt;Dependencies are cached separately.&lt;/p&gt;

&lt;p&gt;If only source code changes, Docker skips reinstalling packages.&lt;/p&gt;




&lt;h2&gt;
  
  
  ❌ Bad Pattern
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; . .&lt;/span&gt;
&lt;span class="k"&gt;RUN &lt;/span&gt;npm &lt;span class="nb"&gt;install&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Any file change invalidates cache.&lt;/p&gt;

&lt;p&gt;Build becomes slower.&lt;/p&gt;




&lt;h2&gt;
  
  
  📁 Docker Volumes
&lt;/h2&gt;

&lt;p&gt;Containers are ephemeral.&lt;/p&gt;

&lt;p&gt;Data disappears after container removal.&lt;/p&gt;

&lt;p&gt;Volumes solve this problem.&lt;/p&gt;




&lt;h2&gt;
  
  
  Create Volume
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker volume create mydata
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Use volume:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker run &lt;span class="nt"&gt;-v&lt;/span&gt; mydata:/data nginx
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🌐 Docker Networking
&lt;/h2&gt;

&lt;p&gt;Containers communicate using Docker networks.&lt;/p&gt;

&lt;p&gt;Create network:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker network create mynetwork
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Run containers inside same network.&lt;/p&gt;

&lt;p&gt;Useful for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;APIs&lt;/li&gt;
&lt;li&gt;Databases&lt;/li&gt;
&lt;li&gt;Microservices&lt;/li&gt;
&lt;li&gt;Internal communication&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  🧹 Essential Docker Commands
&lt;/h3&gt;




&lt;h2&gt;
  
  
  📦 Images
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker images
docker pull nginx
docker build &lt;span class="nt"&gt;-t&lt;/span&gt; myapp &lt;span class="nb"&gt;.&lt;/span&gt;
docker push username/myapp:v1
docker rmi image_id
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🐳 Containers
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker ps
docker ps &lt;span class="nt"&gt;-a&lt;/span&gt;
docker stop container_id
docker &lt;span class="nb"&gt;rm &lt;/span&gt;container_id
docker logs &lt;span class="nt"&gt;-f&lt;/span&gt; container_id
docker &lt;span class="nb"&gt;exec&lt;/span&gt; &lt;span class="nt"&gt;-it&lt;/span&gt; container_id sh
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🧽 Cleanup
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker system prune
docker volume prune
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🔥 Why Docker Became So Popular
&lt;/h2&gt;

&lt;p&gt;Docker transformed software deployment because it provides:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Environment consistency&lt;/li&gt;
&lt;li&gt;Faster deployments&lt;/li&gt;
&lt;li&gt;Infrastructure portability&lt;/li&gt;
&lt;li&gt;Easy CI/CD integration&lt;/li&gt;
&lt;li&gt;Better scalability&lt;/li&gt;
&lt;li&gt;Microservices support&lt;/li&gt;
&lt;li&gt;Cloud-native compatibility&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  ☁️ Docker in Modern DevOps
&lt;/h2&gt;

&lt;p&gt;Docker is now everywhere.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Technology&lt;/th&gt;
&lt;th&gt;Docker Usage&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Kubernetes&lt;/td&gt;
&lt;td&gt;Runs containers&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;CI/CD&lt;/td&gt;
&lt;td&gt;Build &amp;amp; deploy&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Cloud Platforms&lt;/td&gt;
&lt;td&gt;Container hosting&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;DevSecOps&lt;/td&gt;
&lt;td&gt;Isolated workloads&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Microservices&lt;/td&gt;
&lt;td&gt;Service packaging&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  🔐 Docker Security Basics
&lt;/h2&gt;

&lt;p&gt;Important security practices:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Use minimal base images&lt;/li&gt;
&lt;li&gt;Avoid running as root&lt;/li&gt;
&lt;li&gt;Scan images regularly&lt;/li&gt;
&lt;li&gt;Keep dependencies updated&lt;/li&gt;
&lt;li&gt;Use signed images&lt;/li&gt;
&lt;li&gt;Remove unused containers/images&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🏭 Real-World Docker &amp;amp; K8s Workflow
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzq6l2q7qqosf94imd00t.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzq6l2q7qqosf94imd00t.png" alt="Docker WorkFlow" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  🚀 Docker Best Practices
&lt;/h2&gt;




&lt;h2&gt;
  
  
  ✅ Use Smaller Images
&lt;/h2&gt;

&lt;p&gt;Prefer:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="s"&gt; node:20-alpine&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Instead of huge base images.&lt;/p&gt;

&lt;p&gt;Smaller images:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Pull faster&lt;/li&gt;
&lt;li&gt;Reduce attack surface&lt;/li&gt;
&lt;li&gt;Save storage&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  ✅ Always Use &lt;code&gt;.dockerignore&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;node_modules
.git
.env
*.log
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This reduces build size and prevents accidental secret leaks.&lt;/p&gt;




&lt;h2&gt;
  
  
  ✅ Multi-Stage Builds
&lt;/h2&gt;

&lt;p&gt;Use one stage for building.&lt;/p&gt;

&lt;p&gt;Use another minimal stage for production.&lt;/p&gt;




&lt;h2&gt;
  
  
  ✅ Tag Images Properly
&lt;/h2&gt;

&lt;p&gt;Bad:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;latest
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Good:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;v1.0.2
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ✅ Don’t Run Containers as Root
&lt;/h2&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;RUN &lt;/span&gt;adduser &lt;span class="nt"&gt;-S&lt;/span&gt; appuser
&lt;span class="k"&gt;USER&lt;/span&gt;&lt;span class="s"&gt; appuser&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🎭 Multi-Stage Build Example
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="c"&gt;# Stage 1 — Build&lt;/span&gt;
&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;node:20-alpine&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;AS&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;builder&lt;/span&gt;

&lt;span class="k"&gt;WORKDIR&lt;/span&gt;&lt;span class="s"&gt; /app&lt;/span&gt;

&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; package*.json ./&lt;/span&gt;

&lt;span class="k"&gt;RUN &lt;/span&gt;npm ci

&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; . .&lt;/span&gt;

&lt;span class="k"&gt;RUN &lt;/span&gt;npm run build

&lt;span class="c"&gt;# Stage 2 — Production&lt;/span&gt;
&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="s"&gt; node:20-alpine&lt;/span&gt;

&lt;span class="k"&gt;WORKDIR&lt;/span&gt;&lt;span class="s"&gt; /app&lt;/span&gt;

&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; --from=builder /app/dist ./dist&lt;/span&gt;
&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; --from=builder /app/node_modules ./node_modules&lt;/span&gt;

&lt;span class="k"&gt;EXPOSE&lt;/span&gt;&lt;span class="s"&gt; 3000&lt;/span&gt;

&lt;span class="k"&gt;CMD&lt;/span&gt;&lt;span class="s"&gt; ["node", "dist/index.js"]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  📚 Final Thoughts
&lt;/h2&gt;

&lt;p&gt;Docker completely changed how modern applications are built and deployed.&lt;/p&gt;

&lt;p&gt;Understanding:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Containers&lt;/li&gt;
&lt;li&gt;Docker Images&lt;/li&gt;
&lt;li&gt;Dockerfiles&lt;/li&gt;
&lt;li&gt;Layers&lt;/li&gt;
&lt;li&gt;Volumes&lt;/li&gt;
&lt;li&gt;Networking&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;is now a fundamental engineering skill.&lt;br&gt;
Because modern infrastructure runs on containers.&lt;/p&gt;

&lt;p&gt;most popular alternatives to Docker for containerization and container runtime workflows:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Podman&lt;/li&gt;
&lt;li&gt;containerd&lt;/li&gt;
&lt;li&gt;CRI-O&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🎯 Quick Recap
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Concept&lt;/th&gt;
&lt;th&gt;Meaning&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Container&lt;/td&gt;
&lt;td&gt;Isolated runtime&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Docker Image&lt;/td&gt;
&lt;td&gt;Blueprint/template&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Dockerfile&lt;/td&gt;
&lt;td&gt;Build instructions&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Container&lt;/td&gt;
&lt;td&gt;Running image instance&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Volume&lt;/td&gt;
&lt;td&gt;Persistent storage&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Network&lt;/td&gt;
&lt;td&gt;Container communication&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

</description>
      <category>masterclassdevsecops</category>
      <category>webdev</category>
      <category>docker</category>
      <category>container</category>
    </item>
    <item>
      <title>Day 5 — Bash Scripting for Automation</title>
      <dc:creator>Rahul Joshi</dc:creator>
      <pubDate>Sat, 16 May 2026 10:36:53 +0000</pubDate>
      <link>https://forem.com/17j/day-5-bash-scripting-for-automation-fih</link>
      <guid>https://forem.com/17j/day-5-bash-scripting-for-automation-fih</guid>
      <description>&lt;p&gt;Modern infrastructure runs on automation.&lt;/p&gt;

&lt;p&gt;Whether you're a:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;DevOps Engineer&lt;/li&gt;
&lt;li&gt;Linux Administrator&lt;/li&gt;
&lt;li&gt;Cloud Engineer&lt;/li&gt;
&lt;li&gt;Cybersecurity Professional&lt;/li&gt;
&lt;li&gt;Backend Developer&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;You will eventually write Bash scripts.&lt;/p&gt;

&lt;p&gt;From automating backups to deploying servers, monitoring systems, managing logs, and running CI/CD pipelines — Bash is everywhere.&lt;/p&gt;

&lt;p&gt;If Linux is the operating system of the internet, then Bash is its automation language.&lt;/p&gt;

&lt;h2&gt;
  
  
  🔗 Resources
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;GitHub Repo:&lt;/strong&gt;&lt;br&gt;
&lt;a href="https://github.com/17J/30-Days-Cloud-DevSecOps-Journey" rel="noopener noreferrer"&gt;https://github.com/17J/30-Days-Cloud-DevSecOps-Journey&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Command Sheet:&lt;/strong&gt;&lt;br&gt;
&lt;a href="https://bash-command-sheets-k51c.vercel.app/" rel="noopener noreferrer"&gt;https://bash-command-sheets-k51c.vercel.app/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Linux Cron Job Scheduler:&lt;/strong&gt;&lt;br&gt;
&lt;a href="https://crontab.guru/" rel="noopener noreferrer"&gt;https://crontab.guru/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;




&lt;p&gt;many beginners get confused between:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Bash&lt;/li&gt;
&lt;li&gt;SH&lt;/li&gt;
&lt;li&gt;ZSH&lt;/li&gt;
&lt;li&gt;Fish&lt;/li&gt;
&lt;li&gt;Dash&lt;/li&gt;
&lt;li&gt;Yum&lt;/li&gt;
&lt;li&gt;Apt&lt;/li&gt;
&lt;li&gt;DNF&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;So before learning Bash scripting, let’s first understand the Linux shell ecosystem.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Understanding Linux Shells &amp;amp; Package Managers
&lt;/h2&gt;

&lt;p&gt;Linux has multiple shells.&lt;/p&gt;

&lt;p&gt;A shell is simply a command interpreter that lets users communicate with the operating system.&lt;/p&gt;

&lt;p&gt;Think of it like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;User → Shell → Linux Kernel → Hardware
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🐚 Popular Linux Shells
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq7fdcpns140aretbvo4u.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq7fdcpns140aretbvo4u.png" alt="bash Scripting" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  📦 Linux Package Managers
&lt;/h2&gt;

&lt;p&gt;Package managers install software.&lt;/p&gt;

&lt;p&gt;Different Linux distributions use different package managers.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Distribution&lt;/th&gt;
&lt;th&gt;Package Manager&lt;/th&gt;
&lt;th&gt;Example&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Ubuntu&lt;/td&gt;
&lt;td&gt;APT&lt;/td&gt;
&lt;td&gt;&lt;code&gt;apt install nginx&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Debian&lt;/td&gt;
&lt;td&gt;APT&lt;/td&gt;
&lt;td&gt;&lt;code&gt;apt update&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;CentOS 7&lt;/td&gt;
&lt;td&gt;YUM&lt;/td&gt;
&lt;td&gt;&lt;code&gt;yum install docker&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;RHEL&lt;/td&gt;
&lt;td&gt;YUM/DNF&lt;/td&gt;
&lt;td&gt;&lt;code&gt;dnf install git&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Fedora&lt;/td&gt;
&lt;td&gt;DNF&lt;/td&gt;
&lt;td&gt;&lt;code&gt;dnf update&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Arch Linux&lt;/td&gt;
&lt;td&gt;Pacman&lt;/td&gt;
&lt;td&gt;&lt;code&gt;pacman -S nginx&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Alpine Linux&lt;/td&gt;
&lt;td&gt;APK&lt;/td&gt;
&lt;td&gt;&lt;code&gt;apk add curl&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  🚀 What is Bash?
&lt;/h2&gt;

&lt;p&gt;Bash stands for:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Bourne Again SHell&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;It is the default shell for most Linux distributions.&lt;/p&gt;

&lt;p&gt;A shell is simply a program that allows users to interact with the operating system.&lt;/p&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;pwd
ls
mkdir &lt;/span&gt;project
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;These commands are executed through the shell.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 What is Bash Scripting?
&lt;/h2&gt;

&lt;p&gt;A Bash script is a file containing Linux commands executed sequentially.&lt;/p&gt;

&lt;p&gt;Instead of manually typing commands repeatedly, you automate them inside a script.&lt;/p&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Hello Rahul"&lt;/span&gt;
&lt;span class="nb"&gt;date
uptime&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Save as:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;hello.sh
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Make executable:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;chmod&lt;/span&gt; +x hello.sh
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;./hello.sh
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ⚡ Why Bash Automation Matters
&lt;/h2&gt;

&lt;p&gt;Without automation:&lt;/p&gt;

&lt;p&gt;❌ Manual server setup&lt;br&gt;
❌ Repetitive deployments&lt;br&gt;
❌ Manual backups&lt;br&gt;
❌ Human errors&lt;br&gt;
❌ Slow operations&lt;/p&gt;

&lt;p&gt;With Bash automation:&lt;/p&gt;

&lt;p&gt;✅ Faster workflows&lt;br&gt;
✅ Repeatable processes&lt;br&gt;
✅ Infrastructure consistency&lt;br&gt;
✅ Reduced human mistakes&lt;br&gt;
✅ Better productivity&lt;/p&gt;


&lt;h2&gt;
  
  
  📂 Bash Script Structure
&lt;/h2&gt;

&lt;p&gt;Basic structure:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="c"&gt;# Comments start with #&lt;/span&gt;

&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Starting Script"&lt;/span&gt;

&lt;span class="c"&gt;# Commands here&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  🔥 Variables in Bash
&lt;/h3&gt;

&lt;p&gt;Variables store data.&lt;/p&gt;




&lt;h3&gt;
  
  
  ✅ Creating Variables
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;name&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"Rahul"&lt;/span&gt;
&lt;span class="nv"&gt;age&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;22
&lt;span class="nv"&gt;city&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"Delhi"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Access variables using &lt;code&gt;$&lt;/code&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="nv"&gt;$name&lt;/span&gt;
&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="nv"&gt;$age&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ⚠️ Important Rule
&lt;/h2&gt;

&lt;p&gt;No spaces around &lt;code&gt;=&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;❌ Wrong:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;name &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"Rahul"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;✅ Correct:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;name&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"Rahul"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  🧾 User Input
&lt;/h3&gt;

&lt;p&gt;Take input dynamically.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Enter your name:"&lt;/span&gt;
&lt;span class="nb"&gt;read &lt;/span&gt;name

&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Welcome &lt;/span&gt;&lt;span class="nv"&gt;$name&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  📌 Command Line Arguments
&lt;/h3&gt;

&lt;p&gt;Arguments passed while running scripts.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"First argument: &lt;/span&gt;&lt;span class="nv"&gt;$1&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;
&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Second argument: &lt;/span&gt;&lt;span class="nv"&gt;$2&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;./script.sh Rahul Linux
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Output:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;First argument: Rahul
Second argument: Linux
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  🔍 Conditional Statements
&lt;/h3&gt;

&lt;p&gt;Conditions allow decision-making.&lt;/p&gt;




&lt;h3&gt;
  
  
  ✅ If Statement
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="nv"&gt;age&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;20

&lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="o"&gt;[&lt;/span&gt; &lt;span class="nv"&gt;$age&lt;/span&gt; &lt;span class="nt"&gt;-ge&lt;/span&gt; 18 &lt;span class="o"&gt;]&lt;/span&gt;
&lt;span class="k"&gt;then
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Adult"&lt;/span&gt;
&lt;span class="k"&gt;fi&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  ✅ If-Else
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="nv"&gt;num&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;5

&lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="o"&gt;[&lt;/span&gt; &lt;span class="nv"&gt;$num&lt;/span&gt; &lt;span class="nt"&gt;-gt&lt;/span&gt; 10 &lt;span class="o"&gt;]&lt;/span&gt;
&lt;span class="k"&gt;then
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Greater than 10"&lt;/span&gt;
&lt;span class="k"&gt;else
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Less than or equal to 10"&lt;/span&gt;
&lt;span class="k"&gt;fi&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  ✅ If-Elif-Else
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="nv"&gt;marks&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;75

&lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="o"&gt;[&lt;/span&gt; &lt;span class="nv"&gt;$marks&lt;/span&gt; &lt;span class="nt"&gt;-ge&lt;/span&gt; 90 &lt;span class="o"&gt;]&lt;/span&gt;
&lt;span class="k"&gt;then
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Grade A"&lt;/span&gt;
&lt;span class="k"&gt;elif&lt;/span&gt; &lt;span class="o"&gt;[&lt;/span&gt; &lt;span class="nv"&gt;$marks&lt;/span&gt; &lt;span class="nt"&gt;-ge&lt;/span&gt; 70 &lt;span class="o"&gt;]&lt;/span&gt;
&lt;span class="k"&gt;then
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Grade B"&lt;/span&gt;
&lt;span class="k"&gt;else
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Grade C"&lt;/span&gt;
&lt;span class="k"&gt;fi&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  🧠 Comparison Operators
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Operator&lt;/th&gt;
&lt;th&gt;Meaning&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;-eq&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Equal&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;-ne&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Not equal&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;-gt&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Greater than&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;-lt&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Less than&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;-ge&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Greater or equal&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;-le&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Less or equal&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  🔁 Loops in Bash
&lt;/h2&gt;

&lt;p&gt;Loops repeat tasks automatically.&lt;/p&gt;




&lt;h3&gt;
  
  
  ✅ For Loop
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="k"&gt;for &lt;/span&gt;i &lt;span class="k"&gt;in &lt;/span&gt;1 2 3 4 5
&lt;span class="k"&gt;do
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Number: &lt;/span&gt;&lt;span class="nv"&gt;$i&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;
&lt;span class="k"&gt;done&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  ✅ Range Loop
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="k"&gt;for &lt;/span&gt;i &lt;span class="k"&gt;in&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt;1..10&lt;span class="o"&gt;}&lt;/span&gt;
&lt;span class="k"&gt;do
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="nv"&gt;$i&lt;/span&gt;
&lt;span class="k"&gt;done&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  ✅ While Loop
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="nv"&gt;count&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;1

&lt;span class="k"&gt;while&lt;/span&gt; &lt;span class="o"&gt;[&lt;/span&gt; &lt;span class="nv"&gt;$count&lt;/span&gt; &lt;span class="nt"&gt;-le&lt;/span&gt; 5 &lt;span class="o"&gt;]&lt;/span&gt;
&lt;span class="k"&gt;do
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="nv"&gt;$count&lt;/span&gt;
    &lt;span class="o"&gt;((&lt;/span&gt;count++&lt;span class="o"&gt;))&lt;/span&gt;
&lt;span class="k"&gt;done&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  ✅ Infinite Loop
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="k"&gt;while &lt;/span&gt;&lt;span class="nb"&gt;true
&lt;/span&gt;&lt;span class="k"&gt;do
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Running..."&lt;/span&gt;
    &lt;span class="nb"&gt;sleep &lt;/span&gt;2
&lt;span class="k"&gt;done&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  🔨 Functions in Bash
&lt;/h3&gt;

&lt;p&gt;Functions help organize reusable code.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

greet&lt;span class="o"&gt;()&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt;
    &lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Hello &lt;/span&gt;&lt;span class="nv"&gt;$1&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;
&lt;span class="o"&gt;}&lt;/span&gt;

greet Rahul
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  📦 Arrays in Bash
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="nv"&gt;fruits&lt;/span&gt;&lt;span class="o"&gt;=(&lt;/span&gt;&lt;span class="s2"&gt;"apple"&lt;/span&gt; &lt;span class="s2"&gt;"banana"&lt;/span&gt; &lt;span class="s2"&gt;"mango"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;

&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="k"&gt;${&lt;/span&gt;&lt;span class="nv"&gt;fruits&lt;/span&gt;&lt;span class="p"&gt;[0]&lt;/span&gt;&lt;span class="k"&gt;}&lt;/span&gt;
&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="k"&gt;${&lt;/span&gt;&lt;span class="nv"&gt;fruits&lt;/span&gt;&lt;span class="p"&gt;[1]&lt;/span&gt;&lt;span class="k"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Loop through array:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="k"&gt;for &lt;/span&gt;fruit &lt;span class="k"&gt;in&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="k"&gt;${&lt;/span&gt;&lt;span class="nv"&gt;fruits&lt;/span&gt;&lt;span class="p"&gt;[@]&lt;/span&gt;&lt;span class="k"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;
&lt;span class="k"&gt;do
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="nv"&gt;$fruit&lt;/span&gt;
&lt;span class="k"&gt;done&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  📁 File Operations
&lt;/h2&gt;




&lt;h2&gt;
  
  
  ✅ Check if File Exists
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="o"&gt;[&lt;/span&gt; &lt;span class="nt"&gt;-f&lt;/span&gt; test.txt &lt;span class="o"&gt;]&lt;/span&gt;
&lt;span class="k"&gt;then
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"File exists"&lt;/span&gt;
&lt;span class="k"&gt;else
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"File not found"&lt;/span&gt;
&lt;span class="k"&gt;fi&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ✅ Create File
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;touch &lt;/span&gt;file.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ✅ Append to File
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"New Log Entry"&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&amp;gt;&lt;/span&gt; logs.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ⚙️ Process Automation
&lt;/h2&gt;




&lt;h3&gt;
  
  
  ✅ Kill Process
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;pkill nginx
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  ✅ Restart Service
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;systemctl restart nginx
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  ✅ Check Service Status
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;systemctl status docker
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🕒 Cron Jobs for Scheduling
&lt;/h2&gt;

&lt;p&gt;Cron automates scripts at scheduled times.&lt;/p&gt;

&lt;p&gt;Open cron:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;crontab &lt;span class="nt"&gt;-e&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  ✅ Run Every Day at Midnight
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;0 0 &lt;span class="k"&gt;*&lt;/span&gt; &lt;span class="k"&gt;*&lt;/span&gt; &lt;span class="k"&gt;*&lt;/span&gt; /home/ubuntu/backup.sh
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  ✅ Run Every 5 Minutes
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="k"&gt;*&lt;/span&gt;/5 &lt;span class="k"&gt;*&lt;/span&gt; &lt;span class="k"&gt;*&lt;/span&gt; &lt;span class="k"&gt;*&lt;/span&gt; &lt;span class="k"&gt;*&lt;/span&gt; /home/ubuntu/monitor.sh
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🚀 Real-World Automation Scripts
&lt;/h2&gt;

&lt;p&gt;Now the fun begins.&lt;/p&gt;




&lt;h3&gt;
  
  
  🔥 1️⃣ Automated Backup Script
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="nv"&gt;SOURCE&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"/home/ubuntu/data"&lt;/span&gt;
&lt;span class="nv"&gt;DEST&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"/backup"&lt;/span&gt;

&lt;span class="nv"&gt;DATE&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="si"&gt;$(&lt;/span&gt;&lt;span class="nb"&gt;date&lt;/span&gt; +%Y-%m-%d&lt;span class="si"&gt;)&lt;/span&gt;

&lt;span class="nb"&gt;tar&lt;/span&gt; &lt;span class="nt"&gt;-czf&lt;/span&gt; &lt;span class="nv"&gt;$DEST&lt;/span&gt;/backup-&lt;span class="nv"&gt;$DATE&lt;/span&gt;.tar.gz &lt;span class="nv"&gt;$SOURCE&lt;/span&gt;

&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Backup completed"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;What it does:&lt;/p&gt;

&lt;p&gt;✅ Compresses files&lt;br&gt;
✅ Creates timestamp backup&lt;br&gt;
✅ Automates backup process&lt;/p&gt;


&lt;h3&gt;
  
  
  🔥 2️⃣ Disk Usage Monitoring Script
&lt;/h3&gt;


&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="nv"&gt;THRESHOLD&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;80

&lt;span class="nv"&gt;USAGE&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="si"&gt;$(&lt;/span&gt;&lt;span class="nb"&gt;df&lt;/span&gt; / | &lt;span class="nb"&gt;grep&lt;/span&gt; / | &lt;span class="nb"&gt;awk&lt;/span&gt; &lt;span class="s1"&gt;'{ print $5 }'&lt;/span&gt; | &lt;span class="nb"&gt;sed&lt;/span&gt; &lt;span class="s1"&gt;'s/%//g'&lt;/span&gt;&lt;span class="si"&gt;)&lt;/span&gt;

&lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="o"&gt;[&lt;/span&gt; &lt;span class="nv"&gt;$USAGE&lt;/span&gt; &lt;span class="nt"&gt;-gt&lt;/span&gt; &lt;span class="nv"&gt;$THRESHOLD&lt;/span&gt; &lt;span class="o"&gt;]&lt;/span&gt;
&lt;span class="k"&gt;then
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Disk usage exceeded threshold!"&lt;/span&gt;
&lt;span class="k"&gt;else
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Disk usage normal"&lt;/span&gt;
&lt;span class="k"&gt;fi&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;Useful for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Servers&lt;/li&gt;
&lt;li&gt;Cloud VMs&lt;/li&gt;
&lt;li&gt;Production systems&lt;/li&gt;
&lt;/ul&gt;


&lt;h3&gt;
  
  
  🔥 3️⃣ Website Monitoring Script
&lt;/h3&gt;


&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="nv"&gt;URL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"https://example.com"&lt;/span&gt;

&lt;span class="nv"&gt;STATUS&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="si"&gt;$(&lt;/span&gt;curl &lt;span class="nt"&gt;-o&lt;/span&gt; /dev/null &lt;span class="nt"&gt;-s&lt;/span&gt; &lt;span class="nt"&gt;-w&lt;/span&gt; &lt;span class="s2"&gt;"%{http_code}"&lt;/span&gt; &lt;span class="nv"&gt;$URL&lt;/span&gt;&lt;span class="si"&gt;)&lt;/span&gt;

&lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="o"&gt;[&lt;/span&gt; &lt;span class="nv"&gt;$STATUS&lt;/span&gt; &lt;span class="nt"&gt;-eq&lt;/span&gt; 200 &lt;span class="o"&gt;]&lt;/span&gt;
&lt;span class="k"&gt;then
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Website is UP"&lt;/span&gt;
&lt;span class="k"&gt;else
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Website is DOWN"&lt;/span&gt;
&lt;span class="k"&gt;fi&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  🔥 4️⃣ Auto Deployment Script
&lt;/h3&gt;


&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Pulling latest code..."&lt;/span&gt;

git pull origin main

&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Installing dependencies..."&lt;/span&gt;

npm &lt;span class="nb"&gt;install

echo&lt;/span&gt; &lt;span class="s2"&gt;"Restarting application..."&lt;/span&gt;

pm2 restart app
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;Used heavily in:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;DevOps&lt;/li&gt;
&lt;li&gt;CI/CD&lt;/li&gt;
&lt;li&gt;Production deployments&lt;/li&gt;
&lt;/ul&gt;


&lt;h3&gt;
  
  
  🔥 5️⃣ Log Cleanup Script
&lt;/h3&gt;


&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

find /var/log &lt;span class="nt"&gt;-type&lt;/span&gt; f &lt;span class="nt"&gt;-name&lt;/span&gt; &lt;span class="s2"&gt;"*.log"&lt;/span&gt; &lt;span class="nt"&gt;-mtime&lt;/span&gt; +7 &lt;span class="nt"&gt;-delete&lt;/span&gt;

&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Old logs deleted"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;Deletes logs older than 7 days.&lt;/p&gt;


&lt;h3&gt;
  
  
  🛡️ Error Handling in Bash
&lt;/h3&gt;

&lt;p&gt;Always validate failures.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="nb"&gt;mkdir test

&lt;/span&gt;&lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="o"&gt;[&lt;/span&gt; &lt;span class="nv"&gt;$?&lt;/span&gt; &lt;span class="nt"&gt;-eq&lt;/span&gt; 0 &lt;span class="o"&gt;]&lt;/span&gt;
&lt;span class="k"&gt;then
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Directory created"&lt;/span&gt;
&lt;span class="k"&gt;else
    &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Failed"&lt;/span&gt;
&lt;span class="k"&gt;fi&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;$?&lt;/code&gt; stores previous command status.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;0&lt;/code&gt; = success&lt;/li&gt;
&lt;li&gt;Non-zero = failure&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  📌 Exit Codes
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;exit &lt;/span&gt;0
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Success.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;exit &lt;/span&gt;1
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Failure.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧪 Debugging Bash Scripts
&lt;/h2&gt;




&lt;h3&gt;
  
  
  ✅ Run in Debug Mode
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;bash &lt;span class="nt"&gt;-x&lt;/span&gt; script.sh
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Shows command execution step-by-step.&lt;/p&gt;




&lt;h3&gt;
  
  
  ✅ Strict Mode (Highly Recommended)
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;

&lt;span class="nb"&gt;set&lt;/span&gt; &lt;span class="nt"&gt;-euo&lt;/span&gt; pipefail
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This helps catch:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Undefined variables&lt;/li&gt;
&lt;li&gt;Failed commands&lt;/li&gt;
&lt;li&gt;Pipeline failures&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  ⚡ Bash Automation in DevOps
&lt;/h2&gt;

&lt;p&gt;Bash is heavily used in:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Area&lt;/th&gt;
&lt;th&gt;Usage&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;CI/CD&lt;/td&gt;
&lt;td&gt;Build automation&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Kubernetes&lt;/td&gt;
&lt;td&gt;Cluster scripts&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Docker&lt;/td&gt;
&lt;td&gt;Container automation&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;AWS&lt;/td&gt;
&lt;td&gt;EC2 setup scripts&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Monitoring&lt;/td&gt;
&lt;td&gt;Health checks&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Security&lt;/td&gt;
&lt;td&gt;Log scanning&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Linux&lt;/td&gt;
&lt;td&gt;System administration&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  🔐 Security Best Practices
&lt;/h2&gt;

&lt;p&gt;Never write insecure scripts.&lt;/p&gt;




&lt;h3&gt;
  
  
  ❌ Avoid Hardcoding Passwords
&lt;/h3&gt;

&lt;p&gt;Bad:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;password&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"admin123"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Better:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;read&lt;/span&gt; &lt;span class="nt"&gt;-s&lt;/span&gt; password
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  ✅ Quote Variables
&lt;/h3&gt;

&lt;p&gt;Bad:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;rm&lt;/span&gt; &lt;span class="nt"&gt;-rf&lt;/span&gt; &lt;span class="nv"&gt;$dir&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Good:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;rm&lt;/span&gt; &lt;span class="nt"&gt;-rf&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="nv"&gt;$dir&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  ✅ Validate Inputs
&lt;/h3&gt;

&lt;p&gt;Always sanitize user input.&lt;/p&gt;




&lt;h2&gt;
  
  
  📚 Important Bash Commands Every Engineer Should Know
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Purpose&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;grep&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Search text&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;awk&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Text processing&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;sed&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Stream editing&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;cut&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Extract columns&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;find&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Search files&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;xargs&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Command chaining&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;curl&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;API requests&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;tar&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Archive files&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;cron&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Scheduling&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;systemctl&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Manage services&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ffog2jfx865yrn8mbmwoz.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ffog2jfx865yrn8mbmwoz.png" alt="Bash Flow" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  🚀 Bash vs Python for Automation
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Bash&lt;/th&gt;
&lt;th&gt;Python&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Best for Linux automation&lt;/td&gt;
&lt;td&gt;Best for complex logic&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Fast scripting&lt;/td&gt;
&lt;td&gt;Better readability&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Native shell access&lt;/td&gt;
&lt;td&gt;Huge libraries&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Lightweight&lt;/td&gt;
&lt;td&gt;Cross-platform&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Most DevOps engineers use both.&lt;/p&gt;




&lt;h2&gt;
  
  
  🎯 Best Practices for Bash Scripting
&lt;/h2&gt;

&lt;p&gt;✅ Use meaningful variable names&lt;br&gt;
✅ Add comments&lt;br&gt;
✅ Use functions&lt;br&gt;
✅ Handle errors properly&lt;br&gt;
✅ Use strict mode&lt;br&gt;
✅ Keep scripts modular&lt;br&gt;
✅ Log important actions&lt;br&gt;
✅ Test before production&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Final Thoughts
&lt;/h2&gt;

&lt;p&gt;Bash scripting is one of the most valuable skills in Linux, DevOps, Cloud, and Cybersecurity.&lt;/p&gt;

&lt;p&gt;The engineers who automate repetitive tasks become exponentially more productive.&lt;/p&gt;

&lt;p&gt;Start small:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Automate backups&lt;/li&gt;
&lt;li&gt;Monitor servers&lt;/li&gt;
&lt;li&gt;Deploy applications&lt;/li&gt;
&lt;li&gt;Clean logs&lt;/li&gt;
&lt;li&gt;Schedule tasks&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Over time, Bash becomes your operational superpower.&lt;/p&gt;

</description>
      <category>masterclassdevsecops</category>
      <category>linux</category>
      <category>devops</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Day 4 — Git &amp; GitHub Fundamentals</title>
      <dc:creator>Rahul Joshi</dc:creator>
      <pubDate>Fri, 15 May 2026 06:36:44 +0000</pubDate>
      <link>https://forem.com/17j/git-github-fundamentals-3029</link>
      <guid>https://forem.com/17j/git-github-fundamentals-3029</guid>
      <description>&lt;p&gt;Modern software development is impossible without version control. Whether you're building applications alone, working in a startup, contributing to open source, or managing enterprise infrastructure — Git and GitHub are at the center of everything.&lt;/p&gt;

&lt;p&gt;From tracking code changes to handling production deployments, Git powers modern engineering workflows.&lt;/p&gt;

&lt;p&gt;In this guide, we’ll deeply cover:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;What Git actually is&lt;/li&gt;
&lt;li&gt;How Git works internally&lt;/li&gt;
&lt;li&gt;Git basics&lt;/li&gt;
&lt;li&gt;Branching strategies&lt;/li&gt;
&lt;li&gt;Pull Requests&lt;/li&gt;
&lt;li&gt;Merge conflicts&lt;/li&gt;
&lt;li&gt;Git workflows&lt;/li&gt;
&lt;li&gt;Essential Git commands&lt;/li&gt;
&lt;li&gt;Best practices used by professional teams&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🔗 Resources
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;GitHub Repo:&lt;/strong&gt;&lt;br&gt;
&lt;a href="https://github.com/17J/30-Days-Cloud-DevSecOps-Journey" rel="noopener noreferrer"&gt;https://github.com/17J/30-Days-Cloud-DevSecOps-Journey&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Command Sheet:&lt;/strong&gt;&lt;br&gt;
&lt;a href="https://git-command-sheet-sigma.vercel.app/" rel="noopener noreferrer"&gt;https://git-command-sheet-sigma.vercel.app/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🌍 What is Git?
&lt;/h2&gt;

&lt;p&gt;Git is a &lt;strong&gt;distributed version control system (DVCS)&lt;/strong&gt; created by Linus Torvalds in 2005.&lt;/p&gt;

&lt;p&gt;Git helps developers:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Track changes in code&lt;/li&gt;
&lt;li&gt;Collaborate safely&lt;/li&gt;
&lt;li&gt;Maintain project history&lt;/li&gt;
&lt;li&gt;Revert mistakes&lt;/li&gt;
&lt;li&gt;Manage releases&lt;/li&gt;
&lt;li&gt;Work on multiple features simultaneously&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🧠 Why Git Was Created
&lt;/h2&gt;

&lt;p&gt;Before Git, developers mainly used centralized systems like:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;SVN&lt;/li&gt;
&lt;li&gt;CVS&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These systems had problems:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Slow performance&lt;/li&gt;
&lt;li&gt;Central server dependency&lt;/li&gt;
&lt;li&gt;Difficult branching&lt;/li&gt;
&lt;li&gt;Risk of losing history&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Git solved these issues by making every developer’s machine a &lt;strong&gt;complete copy of the repository&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;That means:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Faster operations&lt;/li&gt;
&lt;li&gt;Offline work&lt;/li&gt;
&lt;li&gt;Safer collaboration&lt;/li&gt;
&lt;li&gt;Better branching support&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🔥 What Makes Git Powerful?
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Feature&lt;/th&gt;
&lt;th&gt;Why It Matters&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Distributed architecture&lt;/td&gt;
&lt;td&gt;Every developer has full repository history&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Fast branching&lt;/td&gt;
&lt;td&gt;Lightweight feature development&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Snapshots&lt;/td&gt;
&lt;td&gt;Tracks repository states efficiently&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Data integrity&lt;/td&gt;
&lt;td&gt;Uses SHA hashing&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Collaboration&lt;/td&gt;
&lt;td&gt;Multiple developers work safely&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  🌐 What is GitHub?
&lt;/h2&gt;

&lt;p&gt;GitHub is a cloud-based platform that hosts Git repositories.&lt;/p&gt;

&lt;p&gt;GitHub adds:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Remote repository hosting&lt;/li&gt;
&lt;li&gt;Collaboration tools&lt;/li&gt;
&lt;li&gt;Pull Requests&lt;/li&gt;
&lt;li&gt;CI/CD integration&lt;/li&gt;
&lt;li&gt;Code review systems&lt;/li&gt;
&lt;li&gt;Security scanning&lt;/li&gt;
&lt;li&gt;Issue tracking&lt;/li&gt;
&lt;li&gt;Open-source collaboration&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Think of it like this:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Tool&lt;/th&gt;
&lt;th&gt;Purpose&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Git&lt;/td&gt;
&lt;td&gt;Version control engine&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;GitHub&lt;/td&gt;
&lt;td&gt;Collaboration platform&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  ⚙️ Understanding How Git Works Internally
&lt;/h2&gt;

&lt;p&gt;Many beginners struggle here, but once you understand Git’s internal workflow, everything becomes easier.&lt;/p&gt;

&lt;p&gt;Git has &lt;strong&gt;three main areas&lt;/strong&gt;:&lt;/p&gt;




&lt;h2&gt;
  
  
  1️⃣ Working Directory
&lt;/h2&gt;

&lt;p&gt;This is your actual project folder.&lt;/p&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;app.js
package.json
README.md
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You edit files here.&lt;/p&gt;




&lt;h2&gt;
  
  
  2️⃣ Staging Area (Index)
&lt;/h2&gt;

&lt;p&gt;This is Git’s preparation area.&lt;/p&gt;

&lt;p&gt;You choose which changes should go into the next commit.&lt;/p&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git add app.js
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now &lt;code&gt;app.js&lt;/code&gt; is staged.&lt;/p&gt;




&lt;h2&gt;
  
  
  3️⃣ Repository (.git)
&lt;/h2&gt;

&lt;p&gt;This stores:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Commit history&lt;/li&gt;
&lt;li&gt;Branches&lt;/li&gt;
&lt;li&gt;Metadata&lt;/li&gt;
&lt;li&gt;References&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This is Git’s database.&lt;/p&gt;




&lt;h2&gt;
  
  
  📦 Git Repository Structure
&lt;/h2&gt;

&lt;p&gt;When you initialize Git:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git init
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Git creates:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;.git/
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Inside &lt;code&gt;.git&lt;/code&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Objects&lt;/li&gt;
&lt;li&gt;References&lt;/li&gt;
&lt;li&gt;Commit history&lt;/li&gt;
&lt;li&gt;Configuration&lt;/li&gt;
&lt;li&gt;Branch metadata&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;⚠️ Never manually modify &lt;code&gt;.git&lt;/code&gt;.&lt;/p&gt;




&lt;h2&gt;
  
  
  🚀 Git Basics
&lt;/h2&gt;

&lt;h3&gt;
  
  
  📁 Initializing a Repository
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git init
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This turns your project into a Git repository.&lt;/p&gt;




&lt;h3&gt;
  
  
  📥 Cloning a Repository
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git clone https://github.com/user/project.git
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This downloads:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Files&lt;/li&gt;
&lt;li&gt;Commit history&lt;/li&gt;
&lt;li&gt;Branches&lt;/li&gt;
&lt;li&gt;Remote configuration&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  📊 Checking Repository Status
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git status
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Shows:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Modified files&lt;/li&gt;
&lt;li&gt;Staged changes&lt;/li&gt;
&lt;li&gt;Untracked files&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This command becomes your best friend.&lt;/p&gt;




&lt;h3&gt;
  
  
  ➕ Staging Changes
&lt;/h3&gt;

&lt;p&gt;Stage everything:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git add &lt;span class="nb"&gt;.&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Stage a single file:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git add server.js
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  💾 Creating Commits
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git commit &lt;span class="nt"&gt;-m&lt;/span&gt; &lt;span class="s2"&gt;"Added authentication middleware"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;A commit is:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A snapshot&lt;/li&gt;
&lt;li&gt;A checkpoint&lt;/li&gt;
&lt;li&gt;A historical record&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  🧾 Good Commit Messages
&lt;/h3&gt;

&lt;p&gt;❌ Bad:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git commit &lt;span class="nt"&gt;-m&lt;/span&gt; &lt;span class="s2"&gt;"fix"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;✅ Good:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git commit &lt;span class="nt"&gt;-m&lt;/span&gt; &lt;span class="s2"&gt;"Fixed JWT token expiration handling"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Professional teams use:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Clear descriptions&lt;/li&gt;
&lt;li&gt;Small commits&lt;/li&gt;
&lt;li&gt;Atomic changes&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🌿 Understanding Branches
&lt;/h2&gt;

&lt;p&gt;Branches are one of Git’s biggest strengths.&lt;/p&gt;

&lt;p&gt;A branch is simply a movable pointer to commits.&lt;/p&gt;




&lt;h2&gt;
  
  
  🏗️ Why Branches Matter
&lt;/h2&gt;

&lt;p&gt;Without branches:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Everyone edits the same code&lt;/li&gt;
&lt;li&gt;Features collide&lt;/li&gt;
&lt;li&gt;Production becomes unstable&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Branches solve this.&lt;/p&gt;




&lt;h2&gt;
  
  
  🔹 Creating Branches
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git branch feature-login
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Switch to branch:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git checkout feature-login
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Modern shortcut:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git checkout &lt;span class="nt"&gt;-b&lt;/span&gt; feature-login
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🔍 Viewing Branches
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git branch
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Current branch shows:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="k"&gt;*&lt;/span&gt; main
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🔀 Merging Branches
&lt;/h2&gt;

&lt;p&gt;Merge feature into main:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git checkout main
git merge feature-login
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Git combines histories.&lt;/p&gt;




&lt;h2&gt;
  
  
  ⚠️ Merge Conflicts
&lt;/h2&gt;

&lt;p&gt;Conflicts happen when:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Two developers edit the same lines&lt;/li&gt;
&lt;li&gt;Git cannot automatically decide&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Example conflict:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="o"&gt;&amp;lt;&amp;lt;&amp;lt;&amp;lt;&amp;lt;&amp;lt;&lt;/span&gt;&amp;lt; HEAD
console.log&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;"Old Code"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="o"&gt;=======&lt;/span&gt;
console.log&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;"New Code"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="o"&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;/span&gt; feature-login
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You must manually resolve it.&lt;/p&gt;




&lt;h2&gt;
  
  
  🌳 Branching Strategies
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1️⃣ Feature Branch Workflow
&lt;/h3&gt;

&lt;p&gt;Each feature gets a separate branch.&lt;/p&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;feature-payment
feature-auth
feature-dashboard
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Flow
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Create branch&lt;/li&gt;
&lt;li&gt;Develop feature&lt;/li&gt;
&lt;li&gt;Open Pull Request&lt;/li&gt;
&lt;li&gt;Review&lt;/li&gt;
&lt;li&gt;Merge&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Advantages
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Cleaner history&lt;/li&gt;
&lt;li&gt;Safer development&lt;/li&gt;
&lt;li&gt;Easy rollback&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Most startups use this.&lt;/p&gt;




&lt;h3&gt;
  
  
  2️⃣ Git Flow
&lt;/h3&gt;

&lt;p&gt;One of the most famous workflows.&lt;/p&gt;

&lt;p&gt;Popularized by &lt;strong&gt;Vincent Driessen&lt;/strong&gt;.&lt;/p&gt;




&lt;h2&gt;
  
  
  Git Flow Branches
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fobiumki6ipr2jmdi1h6c.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fobiumki6ipr2jmdi1h6c.png" alt="Git Flow" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Branch&lt;/th&gt;
&lt;th&gt;Purpose&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;main&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Production-ready&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;develop&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Integration branch&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;feature/*&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;New features&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;release/*&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Release preparation&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;hotfix/*&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Emergency fixes&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  Git Flow Lifecycle
&lt;/h2&gt;

&lt;h3&gt;
  
  
  🔹 Feature Development
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git checkout develop
git checkout &lt;span class="nt"&gt;-b&lt;/span&gt; feature-auth
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  🔹 Release Creation
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git checkout &lt;span class="nt"&gt;-b&lt;/span&gt; release-v1.0
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  🔹 Hotfix Production Bugs
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git checkout main
git checkout &lt;span class="nt"&gt;-b&lt;/span&gt; hotfix-login
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ✅ Advantages
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Organized releases&lt;/li&gt;
&lt;li&gt;Stable production&lt;/li&gt;
&lt;li&gt;Enterprise friendly&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  ❌ Disadvantages
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Complex workflow&lt;/li&gt;
&lt;li&gt;Too many branches&lt;/li&gt;
&lt;li&gt;Slower deployments&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  3️⃣ Trunk-Based Development
&lt;/h3&gt;

&lt;p&gt;Used heavily in:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;DevOps teams&lt;/li&gt;
&lt;li&gt;CI/CD environments&lt;/li&gt;
&lt;li&gt;Cloud-native engineering&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Core idea:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Small commits&lt;/li&gt;
&lt;li&gt;Frequent merges&lt;/li&gt;
&lt;li&gt;Short-lived branches&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Main branch = trunk.&lt;/p&gt;




&lt;h2&gt;
  
  
  ✅ Benefits
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Faster deployments&lt;/li&gt;
&lt;li&gt;Smaller conflicts&lt;/li&gt;
&lt;li&gt;Continuous integration friendly&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Popular in:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Google&lt;/li&gt;
&lt;li&gt;Netflix&lt;/li&gt;
&lt;li&gt;Meta&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🔄 Pull Requests (PRs)
&lt;/h2&gt;

&lt;p&gt;A Pull Request is a proposal to merge code changes.&lt;/p&gt;

&lt;p&gt;PRs are central to modern collaboration.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧩 Pull Request Lifecycle
&lt;/h2&gt;

&lt;h2&gt;
  
  
  Step 1 — Create Branch
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git checkout &lt;span class="nt"&gt;-b&lt;/span&gt; feature-auth
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  Step 2 — Push Branch
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git push origin feature-auth
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  Step 3 — Open PR on GitHub
&lt;/h2&gt;

&lt;p&gt;GitHub compares:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Source branch&lt;/li&gt;
&lt;li&gt;Target branch&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Step 4 — Code Review
&lt;/h2&gt;

&lt;p&gt;Teams review:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Logic&lt;/li&gt;
&lt;li&gt;Security&lt;/li&gt;
&lt;li&gt;Readability&lt;/li&gt;
&lt;li&gt;Performance&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Step 5 — CI/CD Runs
&lt;/h2&gt;

&lt;p&gt;Automated checks:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Tests&lt;/li&gt;
&lt;li&gt;Linting&lt;/li&gt;
&lt;li&gt;Security scans&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Step 6 — Merge PR
&lt;/h2&gt;

&lt;p&gt;Once approved:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Squash merge&lt;/li&gt;
&lt;li&gt;Rebase merge&lt;/li&gt;
&lt;li&gt;Standard merge&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🔐 Why Pull Requests Matter
&lt;/h2&gt;

&lt;p&gt;PRs improve:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Code quality&lt;/li&gt;
&lt;li&gt;Security&lt;/li&gt;
&lt;li&gt;Team collaboration&lt;/li&gt;
&lt;li&gt;Knowledge sharing&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;They act like a checkpoint before production.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Types of Git Merges
&lt;/h2&gt;

&lt;h3&gt;
  
  
  🔹 Fast Forward Merge
&lt;/h3&gt;

&lt;p&gt;Simple linear merge.&lt;/p&gt;

&lt;p&gt;Occurs when no divergence exists.&lt;/p&gt;




&lt;h3&gt;
  
  
  🔹 Three-Way Merge
&lt;/h3&gt;

&lt;p&gt;Git creates a merge commit.&lt;/p&gt;

&lt;p&gt;Most common in teams.&lt;/p&gt;




&lt;h3&gt;
  
  
  🔹 Squash Merge
&lt;/h3&gt;

&lt;p&gt;Combines all commits into one.&lt;/p&gt;

&lt;p&gt;Creates cleaner history.&lt;/p&gt;




&lt;h3&gt;
  
  
  🔹 Rebase
&lt;/h3&gt;

&lt;p&gt;Moves commits on top of the latest branch.&lt;/p&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git rebase main
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Benefits
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Linear history&lt;/li&gt;
&lt;li&gt;Cleaner logs&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Risk
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Can rewrite history&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  ⚙️ Common Git Workflows
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1️⃣ Centralized Workflow
&lt;/h3&gt;

&lt;p&gt;Everyone pushes to the same branch.&lt;/p&gt;

&lt;p&gt;Simple but risky.&lt;/p&gt;

&lt;p&gt;Best for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Small teams&lt;/li&gt;
&lt;li&gt;Learning&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  2️⃣ Feature Branch Workflow
&lt;/h3&gt;

&lt;p&gt;Separate branches for features.&lt;/p&gt;

&lt;p&gt;Most commonly used workflow today.&lt;/p&gt;




&lt;h3&gt;
  
  
  3️⃣ Forking Workflow
&lt;/h3&gt;

&lt;p&gt;Mostly used in open source.&lt;/p&gt;

&lt;h3&gt;
  
  
  Flow
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Fork repository&lt;/li&gt;
&lt;li&gt;Clone fork&lt;/li&gt;
&lt;li&gt;Create branch&lt;/li&gt;
&lt;li&gt;Push changes&lt;/li&gt;
&lt;li&gt;Open PR to original repo&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Used heavily on GitHub.&lt;/p&gt;




&lt;h2&gt;
  
  
  🚨 Common Git Problems
&lt;/h2&gt;

&lt;h3&gt;
  
  
  ❌ Detached HEAD State
&lt;/h3&gt;

&lt;p&gt;Occurs when checking out commits directly.&lt;/p&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git checkout 93f4c2
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You are no longer on a branch.&lt;/p&gt;




&lt;h3&gt;
  
  
  ❌ Force Push Problems
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git push &lt;span class="nt"&gt;--force&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Dangerous because:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Rewrites history&lt;/li&gt;
&lt;li&gt;Can delete teammates’ work&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Use carefully.&lt;/p&gt;




&lt;h3&gt;
  
  
  ❌ Huge Commits
&lt;/h3&gt;

&lt;p&gt;Huge commits are bad because:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Hard to review&lt;/li&gt;
&lt;li&gt;Hard to debug&lt;/li&gt;
&lt;li&gt;Hard to revert&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🧹 Git Best Practices
&lt;/h2&gt;

&lt;h3&gt;
  
  
  ✅ Commit Frequently
&lt;/h3&gt;

&lt;p&gt;Small commits = easier debugging.&lt;/p&gt;




&lt;h3&gt;
  
  
  ✅ Use Meaningful Branch Names
&lt;/h3&gt;

&lt;p&gt;✅ Good:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;feature-payment-api
bugfix-auth-timeout
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;❌ Bad:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;test123
newbranch
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  ✅ Protect Main Branch
&lt;/h3&gt;

&lt;p&gt;Never directly push production-breaking code.&lt;/p&gt;




&lt;h3&gt;
  
  
  ✅ Pull Before Push
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git pull origin main
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Avoids conflicts.&lt;/p&gt;




&lt;h3&gt;
  
  
  ✅ Use &lt;code&gt;.gitignore&lt;/code&gt;
&lt;/h3&gt;

&lt;p&gt;Prevent sensitive or unnecessary files.&lt;/p&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;node_modules/
.env
dist/
coverage/
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🔐 Git in DevOps &amp;amp; CI/CD
&lt;/h2&gt;

&lt;p&gt;Git is deeply integrated into:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;CI/CD pipelines&lt;/li&gt;
&lt;li&gt;Infrastructure as Code&lt;/li&gt;
&lt;li&gt;Kubernetes deployments&lt;/li&gt;
&lt;li&gt;DevSecOps automation&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Modern pipelines trigger automatically when:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Code is pushed&lt;/li&gt;
&lt;li&gt;PRs are merged&lt;/li&gt;
&lt;li&gt;Releases are tagged&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Popular integrations:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;GitHub Actions&lt;/li&gt;
&lt;li&gt;GitLab CI/CD&lt;/li&gt;
&lt;li&gt;Jenkins&lt;/li&gt;
&lt;li&gt;CircleCI&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🚀 Final Thoughts
&lt;/h2&gt;

&lt;p&gt;Git is more than just commands.&lt;/p&gt;

&lt;p&gt;It’s a system that enables:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Safe collaboration&lt;/li&gt;
&lt;li&gt;Scalable development&lt;/li&gt;
&lt;li&gt;Reliable deployments&lt;/li&gt;
&lt;li&gt;Modern DevOps practices&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Once you truly understand:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Branching&lt;/li&gt;
&lt;li&gt;Commits&lt;/li&gt;
&lt;li&gt;PRs&lt;/li&gt;
&lt;li&gt;Workflows&lt;/li&gt;
&lt;li&gt;Collaboration strategies&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;…you stop being just a coder and start working like a professional software engineer.&lt;/p&gt;

&lt;p&gt;The best way to master Git is:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Use it daily&lt;/li&gt;
&lt;li&gt;Break things&lt;/li&gt;
&lt;li&gt;Resolve conflicts&lt;/li&gt;
&lt;li&gt;Work on real projects&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Because every professional developer spends a huge part of their career inside Git.&lt;/p&gt;

</description>
      <category>git</category>
      <category>masterclassdevsecops</category>
      <category>webdev</category>
      <category>software</category>
    </item>
    <item>
      <title>Day 3 — Networking Fundamentals</title>
      <dc:creator>Rahul Joshi</dc:creator>
      <pubDate>Thu, 14 May 2026 04:57:58 +0000</pubDate>
      <link>https://forem.com/17j/day-3-networking-fundamentals-3ao6</link>
      <guid>https://forem.com/17j/day-3-networking-fundamentals-3ao6</guid>
      <description>&lt;p&gt;🌐 Networking Fundamentals for DevOps &amp;amp; DevSecOps Engineers&lt;/p&gt;

&lt;p&gt;If you’re entering the world of DevOps, Cloud, Cybersecurity, or DevSecOps, there’s one thing you simply cannot escape:&lt;/p&gt;

&lt;p&gt;👉 &lt;strong&gt;Networking.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;You can automate Kubernetes deployments, build CI/CD pipelines, scan containers, or secure APIs all day long…&lt;br&gt;
But if you don’t understand how systems communicate over a network, eventually things will break — and debugging becomes pure pain.&lt;/p&gt;

&lt;p&gt;And trust me…&lt;/p&gt;

&lt;p&gt;Every DevOps engineer has faced moments like:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;“Why is the service unreachable?”&lt;/li&gt;
&lt;li&gt;“Why is DNS failing?”&lt;/li&gt;
&lt;li&gt;“Why is port 443 blocked?”&lt;/li&gt;
&lt;li&gt;“Why is the pod timing out?”&lt;/li&gt;
&lt;li&gt;“Why does curl work but browser doesn’t?”&lt;/li&gt;
&lt;li&gt;“Why is UDP packet loss happening?”&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;At that moment, networking fundamentals stop being “theory” and become survival skills.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Github Repo:&lt;/strong&gt; &lt;a href="https://github.com/17J/30-Days-Cloud-DevSecOps-Journey" rel="noopener noreferrer"&gt;https://github.com/17J/30-Days-Cloud-DevSecOps-Journey&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;


&lt;h2&gt;
  
  
  🚀 Why Networking Matters in Modern Tech
&lt;/h2&gt;

&lt;p&gt;Today everything is connected:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Cloud servers&lt;/li&gt;
&lt;li&gt;Kubernetes clusters&lt;/li&gt;
&lt;li&gt;APIs&lt;/li&gt;
&lt;li&gt;Microservices&lt;/li&gt;
&lt;li&gt;Databases&lt;/li&gt;
&lt;li&gt;CI/CD runners&lt;/li&gt;
&lt;li&gt;Containers&lt;/li&gt;
&lt;li&gt;Security tools&lt;/li&gt;
&lt;li&gt;VPNs&lt;/li&gt;
&lt;li&gt;CDNs&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Even your Git push travels through multiple networking layers before reaching GitHub.&lt;/p&gt;

&lt;p&gt;Understanding networking helps you:&lt;/p&gt;

&lt;p&gt;✅ Debug faster&lt;br&gt;
✅ Secure systems properly&lt;br&gt;
✅ Understand cloud architecture&lt;br&gt;
✅ Configure firewalls&lt;br&gt;
✅ Work with Kubernetes confidently&lt;br&gt;
✅ Handle load balancers &amp;amp; reverse proxies&lt;br&gt;
✅ Understand attacks like DDoS, MITM, spoofing, scanning, etc.&lt;/p&gt;


&lt;h2&gt;
  
  
  🧠 What is Networking?
&lt;/h2&gt;

&lt;p&gt;In simple words:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Networking is the communication between devices.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;When two systems exchange data, they follow a set of rules called &lt;strong&gt;protocols&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Example:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Your browser requests a website&lt;/li&gt;
&lt;li&gt;DNS converts domain → IP&lt;/li&gt;
&lt;li&gt;TCP establishes connection&lt;/li&gt;
&lt;li&gt;HTTPS encrypts communication&lt;/li&gt;
&lt;li&gt;Server sends response&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;All this happens in milliseconds.&lt;/p&gt;

&lt;p&gt;Crazy, right?&lt;/p&gt;


&lt;h2&gt;
  
  
  🏢 OSI Model — The Foundation of Networking
&lt;/h2&gt;

&lt;p&gt;The &lt;strong&gt;OSI Model (Open Systems Interconnection)&lt;/strong&gt; is a conceptual framework used to understand how data travels across a network.&lt;/p&gt;

&lt;p&gt;It has &lt;strong&gt;7 layers&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Think of it like delivering a package through multiple departments.&lt;/p&gt;


&lt;h2&gt;
  
  
  📚 The 7 Layers of OSI Model
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fri4fagmoj6kuhoycsqbr.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fri4fagmoj6kuhoycsqbr.png" alt="OSI Model" width="800" height="418"&gt;&lt;/a&gt;&lt;/p&gt;


&lt;h2&gt;
  
  
  🔍 Understanding Each Layer
&lt;/h2&gt;


&lt;h3&gt;
  
  
  7️⃣ Application Layer
&lt;/h3&gt;

&lt;p&gt;This is where users interact.&lt;/p&gt;

&lt;p&gt;Protocols:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;HTTP&lt;/li&gt;
&lt;li&gt;HTTPS&lt;/li&gt;
&lt;li&gt;DNS&lt;/li&gt;
&lt;li&gt;FTP&lt;/li&gt;
&lt;li&gt;SMTP&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Example:&lt;br&gt;
When you open YouTube in browser.&lt;/p&gt;


&lt;h3&gt;
  
  
  6️⃣ Presentation Layer
&lt;/h3&gt;

&lt;p&gt;Handles:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Encryption&lt;/li&gt;
&lt;li&gt;Compression&lt;/li&gt;
&lt;li&gt;Data formatting&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Examples:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;SSL/TLS encryption&lt;/li&gt;
&lt;li&gt;JPEG/PNG formatting&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This layer makes HTTPS secure.&lt;/p&gt;


&lt;h3&gt;
  
  
  5️⃣ Session Layer
&lt;/h3&gt;

&lt;p&gt;Responsible for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Opening sessions&lt;/li&gt;
&lt;li&gt;Maintaining sessions&lt;/li&gt;
&lt;li&gt;Closing sessions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Example:&lt;br&gt;
Keeping your login session active.&lt;/p&gt;


&lt;h3&gt;
  
  
  4️⃣ Transport Layer
&lt;/h3&gt;

&lt;p&gt;This is where &lt;strong&gt;TCP and UDP&lt;/strong&gt; live.&lt;/p&gt;

&lt;p&gt;Responsibilities:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Data delivery&lt;/li&gt;
&lt;li&gt;Error checking&lt;/li&gt;
&lt;li&gt;Packet sequencing&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Protocols:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;TCP&lt;/li&gt;
&lt;li&gt;UDP&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This layer is extremely important in DevOps and Security.&lt;/p&gt;


&lt;h3&gt;
  
  
  3️⃣ Network Layer
&lt;/h3&gt;

&lt;p&gt;This layer handles:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;IP addressing&lt;/li&gt;
&lt;li&gt;Routing&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Protocol:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;IP (Internet Protocol)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Routers operate here.&lt;/p&gt;


&lt;h3&gt;
  
  
  2️⃣ Data Link Layer
&lt;/h3&gt;

&lt;p&gt;Handles:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;MAC addresses&lt;/li&gt;
&lt;li&gt;Local network communication&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Switches operate here.&lt;/p&gt;


&lt;h3&gt;
  
  
  1️⃣ Physical Layer
&lt;/h3&gt;

&lt;p&gt;The actual hardware:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Cables&lt;/li&gt;
&lt;li&gt;Fiber optics&lt;/li&gt;
&lt;li&gt;Wi-Fi signals&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This is the physical transmission layer.&lt;/p&gt;


&lt;h2&gt;
  
  
  ⚡ TCP/IP Model — The Real Internet Model
&lt;/h2&gt;

&lt;p&gt;Now here’s the interesting part:&lt;/p&gt;

&lt;p&gt;The internet doesn’t actually use the full OSI model directly.&lt;/p&gt;

&lt;p&gt;It mainly follows the &lt;strong&gt;TCP/IP Model&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fklh550qcyc8sghrmr37u.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fklh550qcyc8sghrmr37u.png" alt="TCP IP Model" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;


&lt;h3&gt;
  
  
  📚 TCP/IP Layers
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;TCP/IP Layer&lt;/th&gt;
&lt;th&gt;OSI Equivalent&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Application&lt;/td&gt;
&lt;td&gt;OSI 5,6,7&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Transport&lt;/td&gt;
&lt;td&gt;OSI 4&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Internet&lt;/td&gt;
&lt;td&gt;OSI 3&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Network Access&lt;/td&gt;
&lt;td&gt;OSI 1,2&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;


&lt;h2&gt;
  
  
  🤔 OSI vs TCP/IP
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;OSI&lt;/th&gt;
&lt;th&gt;TCP/IP&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Theoretical model&lt;/td&gt;
&lt;td&gt;Practical model&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;7 layers&lt;/td&gt;
&lt;td&gt;4 layers&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Used for understanding&lt;/td&gt;
&lt;td&gt;Used in real internet&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;More detailed&lt;/td&gt;
&lt;td&gt;More implementation-focused&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;


&lt;h2&gt;
  
  
  🌍 What is an IP Address?
&lt;/h2&gt;

&lt;p&gt;Every device connected to a network needs an identity.&lt;/p&gt;

&lt;p&gt;That identity is called an &lt;strong&gt;IP Address&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;192.168.1.1
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Think of IP like a house address for devices.&lt;/p&gt;

&lt;p&gt;Without IP addresses:&lt;br&gt;
❌ Internet communication is impossible.&lt;/p&gt;


&lt;h3&gt;
  
  
  🧩 Types of IP Addresses
&lt;/h3&gt;
&lt;h3&gt;
  
  
  IPv4
&lt;/h3&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;192.168.0.1
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;32-bit addressing.&lt;/p&gt;

&lt;p&gt;Limited addresses.&lt;/p&gt;




&lt;h3&gt;
  
  
  IPv6
&lt;/h3&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;2001:0db8:85a3::8a2e:0370:7334
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;128-bit addressing.&lt;/p&gt;

&lt;p&gt;Created because IPv4 addresses were running out.&lt;/p&gt;




&lt;h2&gt;
  
  
  🏠 Public vs Private IP
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Type&lt;/th&gt;
&lt;th&gt;Usage&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Public IP&lt;/td&gt;
&lt;td&gt;Internet-facing&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Private IP&lt;/td&gt;
&lt;td&gt;Internal networks&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Private ranges:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;10.0.0.0/8
172.16.0.0/12
192.168.0.0/16
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🌐 What is DNS?
&lt;/h2&gt;

&lt;p&gt;DNS = &lt;strong&gt;Domain Name System&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;DNS converts human-friendly names into IP addresses.&lt;/p&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;google.com → 142.250.x.x
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Because humans remember names better than numbers.&lt;/p&gt;




&lt;h2&gt;
  
  
  🔥 DNS Flow
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fgqzeabgmvx8pjhphpooj.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fgqzeabgmvx8pjhphpooj.png" alt="DNS Flow" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  🛠 Common DNS Record Types
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Record&lt;/th&gt;
&lt;th&gt;Purpose&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;A&lt;/td&gt;
&lt;td&gt;Maps domain → IPv4&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;AAAA&lt;/td&gt;
&lt;td&gt;Maps domain → IPv6&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;CNAME&lt;/td&gt;
&lt;td&gt;Alias&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;MX&lt;/td&gt;
&lt;td&gt;Mail server&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;TXT&lt;/td&gt;
&lt;td&gt;Verification/security&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  🌍 What is HTTP?
&lt;/h2&gt;

&lt;p&gt;HTTP = &lt;strong&gt;HyperText Transfer Protocol&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Used for communication between:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Browser&lt;/li&gt;
&lt;li&gt;Server&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;HTTP is stateless.&lt;/p&gt;




&lt;h2&gt;
  
  
  📦 Example HTTP Request
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight http"&gt;&lt;code&gt;&lt;span class="nf"&gt;GET&lt;/span&gt; &lt;span class="nn"&gt;/index.html&lt;/span&gt; &lt;span class="k"&gt;HTTP&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="m"&gt;1.1&lt;/span&gt;
&lt;span class="na"&gt;Host&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s"&gt;example.com&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🔒 What is HTTPS?
&lt;/h2&gt;

&lt;p&gt;HTTPS = HTTP + SSL/TLS encryption.&lt;/p&gt;

&lt;p&gt;This secures:&lt;br&gt;
✅ Passwords&lt;br&gt;
✅ Payments&lt;br&gt;
✅ Tokens&lt;br&gt;
✅ Sensitive data&lt;/p&gt;

&lt;p&gt;Without HTTPS:&lt;br&gt;
Attackers can sniff traffic.&lt;/p&gt;


&lt;h2&gt;
  
  
  🔥 HTTP vs HTTPS
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;HTTP&lt;/th&gt;
&lt;th&gt;HTTPS&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Unencrypted&lt;/td&gt;
&lt;td&gt;Encrypted&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Port 80&lt;/td&gt;
&lt;td&gt;Port 443&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Insecure&lt;/td&gt;
&lt;td&gt;Secure&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;


&lt;h2&gt;
  
  
  🚪 What are Ports?
&lt;/h2&gt;

&lt;p&gt;Ports are logical communication endpoints.&lt;/p&gt;

&lt;p&gt;Think of IP as:&lt;br&gt;
🏢 Building Address&lt;/p&gt;

&lt;p&gt;And ports as:&lt;br&gt;
🚪 Room Numbers&lt;/p&gt;


&lt;h2&gt;
  
  
  📚 Common Ports
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Port&lt;/th&gt;
&lt;th&gt;Service&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;22&lt;/td&gt;
&lt;td&gt;SSH&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;53&lt;/td&gt;
&lt;td&gt;DNS&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;80&lt;/td&gt;
&lt;td&gt;HTTP&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;443&lt;/td&gt;
&lt;td&gt;HTTPS&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;3306&lt;/td&gt;
&lt;td&gt;MySQL&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;5432&lt;/td&gt;
&lt;td&gt;PostgreSQL&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;6379&lt;/td&gt;
&lt;td&gt;Redis&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;27017&lt;/td&gt;
&lt;td&gt;MongoDB&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;


&lt;h2&gt;
  
  
  ⚔️ TCP vs UDP
&lt;/h2&gt;

&lt;p&gt;This is one of the most important networking concepts.&lt;/p&gt;


&lt;h3&gt;
  
  
  📦 TCP (Transmission Control Protocol)
&lt;/h3&gt;

&lt;p&gt;TCP is:&lt;br&gt;
✅ Reliable&lt;br&gt;
✅ Connection-oriented&lt;br&gt;
✅ Ordered matters&lt;br&gt;
✅ Error-checked&lt;/p&gt;

&lt;p&gt;Used when data integrity matters.&lt;/p&gt;

&lt;p&gt;Examples:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;HTTPS&lt;/li&gt;
&lt;li&gt;SSH&lt;/li&gt;
&lt;li&gt;FTP&lt;/li&gt;
&lt;li&gt;Database communication&lt;/li&gt;
&lt;/ul&gt;


&lt;h3&gt;
  
  
  🚀 UDP (User Datagram Protocol)
&lt;/h3&gt;

&lt;p&gt;UDP is:&lt;br&gt;
✅ Fast&lt;br&gt;
✅ Lightweight&lt;br&gt;
❌ No guarantee of delivery&lt;/p&gt;

&lt;p&gt;Used when speed matters more than perfection.&lt;/p&gt;

&lt;p&gt;Examples:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Gaming&lt;/li&gt;
&lt;li&gt;Live streaming&lt;/li&gt;
&lt;li&gt;VoIP&lt;/li&gt;
&lt;li&gt;DNS queries&lt;/li&gt;
&lt;/ul&gt;


&lt;h3&gt;
  
  
  🔥 TCP vs UDP Comparison
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Feature&lt;/th&gt;
&lt;th&gt;TCP&lt;/th&gt;
&lt;th&gt;UDP&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Reliable&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Fast&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Ordered&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Connection&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Error Recovery&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;


&lt;h2&gt;
  
  
  🔥 3-Way Handshake
&lt;/h2&gt;

&lt;p&gt;Before TCP communication begins, client and server establish connection using the famous:&lt;/p&gt;

&lt;p&gt;This ensures both systems are ready.&lt;/p&gt;


&lt;h3&gt;
  
  
  📡 Step 1 — SYN
&lt;/h3&gt;

&lt;p&gt;Client sends:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;SYN
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Meaning:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Hey server, can we communicate?”&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h3&gt;
  
  
  📡 Step 2 — SYN-ACK
&lt;/h3&gt;

&lt;p&gt;Server replies:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;SYN-ACK
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Meaning:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Yes, I’m ready.”&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h3&gt;
  
  
  📡 Step 3 — ACK
&lt;/h3&gt;

&lt;p&gt;Client sends:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ACK
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Meaning:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Perfect, let’s start.”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Connection established ✅&lt;/p&gt;




&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frisahr8mmm5f1jwhzhei.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frisahr8mmm5f1jwhzhei.png" alt="Three Way Handshake" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;After this:&lt;br&gt;
Actual data transfer begins.&lt;/p&gt;


&lt;h2&gt;
  
  
  🔥 Why 3-Way Handshake Matters in Security
&lt;/h2&gt;

&lt;p&gt;Understanding handshake helps detect:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;SYN Flood attacks&lt;/li&gt;
&lt;li&gt;Connection hijacking&lt;/li&gt;
&lt;li&gt;Network scanning&lt;/li&gt;
&lt;li&gt;Reconnaissance&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This is heavily used in:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;SOC operations&lt;/li&gt;
&lt;li&gt;Threat detection&lt;/li&gt;
&lt;li&gt;DevSecOps monitoring&lt;/li&gt;
&lt;/ul&gt;


&lt;h2&gt;
  
  
  ☁️ Networking in Cloud &amp;amp; Kubernetes
&lt;/h2&gt;

&lt;p&gt;Now comes the modern world.&lt;/p&gt;

&lt;p&gt;In Kubernetes and Cloud:&lt;/p&gt;

&lt;p&gt;Networking becomes even more important.&lt;/p&gt;

&lt;p&gt;You deal with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Pod networking&lt;/li&gt;
&lt;li&gt;Service discovery&lt;/li&gt;
&lt;li&gt;Ingress controllers&lt;/li&gt;
&lt;li&gt;Load balancers&lt;/li&gt;
&lt;li&gt;DNS resolution&lt;/li&gt;
&lt;li&gt;Service mesh&lt;/li&gt;
&lt;li&gt;Internal routing&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;One small DNS issue can break entire production systems.&lt;/p&gt;


&lt;h2&gt;
  
  
  🔐 Networking + DevSecOps
&lt;/h2&gt;

&lt;p&gt;DevSecOps engineers constantly work with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;WAFs&lt;/li&gt;
&lt;li&gt;Firewalls&lt;/li&gt;
&lt;li&gt;Reverse proxies&lt;/li&gt;
&lt;li&gt;TLS certificates&lt;/li&gt;
&lt;li&gt;Network policies&lt;/li&gt;
&lt;li&gt;VPNs&lt;/li&gt;
&lt;li&gt;Zero Trust networking&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Without networking knowledge:&lt;br&gt;
Security becomes guesswork.&lt;/p&gt;


&lt;h2&gt;
  
  
  🧪 Essential Networking Commands Every Engineer Should Know
&lt;/h2&gt;


&lt;h2&gt;
  
  
  ping
&lt;/h2&gt;

&lt;p&gt;Checks connectivity.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ping google.com
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  nslookup
&lt;/h2&gt;

&lt;p&gt;Checks DNS resolution.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;nslookup google.com
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  curl
&lt;/h2&gt;

&lt;p&gt;Tests HTTP requests.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl https://example.com
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  traceroute
&lt;/h2&gt;

&lt;p&gt;Shows network path.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;traceroute google.com
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  netstat
&lt;/h2&gt;

&lt;p&gt;Shows active connections.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;netstat &lt;span class="nt"&gt;-tulnp&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ss
&lt;/h2&gt;

&lt;p&gt;Modern replacement for netstat.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ss &lt;span class="nt"&gt;-tulnp&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🧠 Real Industry Truth
&lt;/h2&gt;

&lt;p&gt;A lot of engineers jump directly into:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Kubernetes&lt;/li&gt;
&lt;li&gt;Docker&lt;/li&gt;
&lt;li&gt;Cloud&lt;/li&gt;
&lt;li&gt;Terraform&lt;/li&gt;
&lt;li&gt;Security tools&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;But skip networking fundamentals.&lt;/p&gt;

&lt;p&gt;Then later:&lt;br&gt;
everything becomes confusing.&lt;/p&gt;

&lt;p&gt;The best DevOps and Security engineers usually have:&lt;br&gt;
✅ Strong Linux basics&lt;br&gt;
✅ Strong networking understanding&lt;br&gt;
✅ Strong debugging mindset&lt;/p&gt;

&lt;p&gt;Because infrastructure is ultimately just:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Systems communicating with systems.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  🎯 Final Thoughts
&lt;/h2&gt;

&lt;p&gt;Networking is not optional anymore.&lt;/p&gt;

&lt;p&gt;Whether you're:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;DevOps Engineer&lt;/li&gt;
&lt;li&gt;Cloud Engineer&lt;/li&gt;
&lt;li&gt;Backend Developer&lt;/li&gt;
&lt;li&gt;DevSecOps Engineer&lt;/li&gt;
&lt;li&gt;Security Researcher&lt;/li&gt;
&lt;li&gt;SRE&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;You must understand:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;IP&lt;/li&gt;
&lt;li&gt;DNS&lt;/li&gt;
&lt;li&gt;HTTP/HTTPS&lt;/li&gt;
&lt;li&gt;TCP/UDP&lt;/li&gt;
&lt;li&gt;Ports&lt;/li&gt;
&lt;li&gt;OSI Model&lt;/li&gt;
&lt;li&gt;TCP/IP Model&lt;/li&gt;
&lt;li&gt;3-Way Handshake&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These concepts are the backbone of modern infrastructure.&lt;/p&gt;

&lt;p&gt;Once networking clicks in your brain…&lt;/p&gt;

&lt;p&gt;Cloud starts making sense.&lt;br&gt;
Kubernetes starts making sense.&lt;br&gt;
Security starts making sense.&lt;br&gt;
Even debugging becomes easier.&lt;/p&gt;

&lt;p&gt;And honestly?&lt;/p&gt;

&lt;p&gt;Most “complex production issues” eventually come down to:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Networking somewhere broke.&lt;/p&gt;
&lt;/blockquote&gt;

</description>
      <category>devops</category>
      <category>masterclassdevsecops</category>
      <category>networking</category>
      <category>webdev</category>
    </item>
    <item>
      <title>10 DevSecOps Engineer Habits That Separate Good From Great</title>
      <dc:creator>Rahul Joshi</dc:creator>
      <pubDate>Wed, 13 May 2026 10:33:52 +0000</pubDate>
      <link>https://forem.com/17j/10-devsecops-engineer-habits-that-separate-good-from-great-121i</link>
      <guid>https://forem.com/17j/10-devsecops-engineer-habits-that-separate-good-from-great-121i</guid>
      <description>&lt;p&gt;Every company today says they want &lt;em&gt;DevSecOps&lt;/em&gt;.&lt;br&gt;
But very few teams actually build a &lt;strong&gt;security-first engineering culture&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Why?&lt;/p&gt;

&lt;p&gt;Because tools alone don’t create great DevSecOps engineers.&lt;/p&gt;

&lt;p&gt;You can install scanners, buy expensive security platforms, and automate CI/CD pipelines all day long… but the engineers who truly stand out are the ones who build powerful habits behind the scenes.&lt;/p&gt;

&lt;p&gt;And honestly?&lt;/p&gt;

&lt;p&gt;The difference between a &lt;em&gt;good&lt;/em&gt; DevSecOps engineer and a &lt;em&gt;great&lt;/em&gt; one is usually not intelligence.&lt;br&gt;
It’s consistency.&lt;/p&gt;

&lt;p&gt;So if you're trying to grow from:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;“the person who runs scans”
to&lt;/li&gt;
&lt;li&gt;“the engineer teams trust with production security”&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;then these habits matter more than any certification.&lt;/p&gt;

&lt;p&gt;Let’s dive in 👇&lt;/p&gt;




&lt;h2&gt;
  
  
  🛡️ 1️⃣ They Shift Security Left — Automatically
&lt;/h2&gt;

&lt;p&gt;Good engineers run security scans.&lt;/p&gt;

&lt;p&gt;Great engineers make security invisible inside the developer workflow.&lt;/p&gt;

&lt;p&gt;They don’t wait for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;staging deployments&lt;/li&gt;
&lt;li&gt;QA testing&lt;/li&gt;
&lt;li&gt;production incidents&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Instead, they integrate security into:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Git hooks&lt;/li&gt;
&lt;li&gt;Pull Requests&lt;/li&gt;
&lt;li&gt;CI/CD pipelines&lt;/li&gt;
&lt;li&gt;Container builds&lt;/li&gt;
&lt;li&gt;IaC deployments&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Because the earlier you catch a problem, the cheaper it is to fix.&lt;/p&gt;

&lt;p&gt;A great DevSecOps engineer thinks:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“How do I stop insecure code from ever reaching production?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Not:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“How do I detect it later?”&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  ⚡ 2️⃣ They Treat Automation Like Oxygen
&lt;/h2&gt;

&lt;p&gt;If something repetitive exists… they automate it.&lt;/p&gt;

&lt;p&gt;Great DevSecOps engineers hate manual processes because:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;humans forget things&lt;/li&gt;
&lt;li&gt;humans skip steps&lt;/li&gt;
&lt;li&gt;humans get tired&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Automation creates consistency.&lt;/p&gt;

&lt;p&gt;That means automating:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;secret scanning&lt;/li&gt;
&lt;li&gt;dependency checks&lt;/li&gt;
&lt;li&gt;image scanning&lt;/li&gt;
&lt;li&gt;policy enforcement&lt;/li&gt;
&lt;li&gt;patch management&lt;/li&gt;
&lt;li&gt;compliance reporting&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The goal is simple:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Reduce human error as much as possible.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;And in modern cloud-native environments, that habit becomes priceless.&lt;/p&gt;




&lt;h2&gt;
  
  
  🔍 3️⃣ They Read Logs Before Dashboards
&lt;/h2&gt;

&lt;p&gt;Dashboards are beautiful.&lt;/p&gt;

&lt;p&gt;Logs tell the truth.&lt;/p&gt;

&lt;p&gt;Good engineers rely only on monitoring tools.&lt;/p&gt;

&lt;p&gt;Great engineers investigate:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;raw logs&lt;/li&gt;
&lt;li&gt;Kubernetes events&lt;/li&gt;
&lt;li&gt;authentication failures&lt;/li&gt;
&lt;li&gt;container crashes&lt;/li&gt;
&lt;li&gt;unusual traffic patterns&lt;/li&gt;
&lt;li&gt;runtime anomalies&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Because security incidents rarely announce themselves clearly.&lt;/p&gt;

&lt;p&gt;Sometimes the first sign of compromise is:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;a strange API request&lt;/li&gt;
&lt;li&gt;a suspicious outbound connection&lt;/li&gt;
&lt;li&gt;an unexpected container restart&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The best DevSecOps engineers develop an investigator mindset.&lt;/p&gt;




&lt;h2&gt;
  
  
  ☁️ 4️⃣ They Understand Cloud Before Security Tools
&lt;/h2&gt;

&lt;p&gt;One of the biggest mistakes in DevSecOps is learning tools before infrastructure.&lt;/p&gt;

&lt;p&gt;A great engineer deeply understands:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;networking&lt;/li&gt;
&lt;li&gt;IAM&lt;/li&gt;
&lt;li&gt;Kubernetes&lt;/li&gt;
&lt;li&gt;containers&lt;/li&gt;
&lt;li&gt;Linux internals&lt;/li&gt;
&lt;li&gt;cloud architecture&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Because if you don’t understand the system…&lt;/p&gt;

&lt;p&gt;you can’t secure it properly.&lt;/p&gt;

&lt;p&gt;A scanner might tell you:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Port exposed.”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;But experience tells you:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“This network design itself is dangerous.”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;That difference changes careers.&lt;/p&gt;




&lt;h2&gt;
  
  
  🐳 5️⃣ They Think in Attack Paths, Not Alerts
&lt;/h2&gt;

&lt;p&gt;Beginners focus on alerts.&lt;/p&gt;

&lt;p&gt;Experts focus on attack chains.&lt;/p&gt;

&lt;p&gt;Great DevSecOps engineers constantly ask:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;“If this secret leaks… what happens next?”&lt;/li&gt;
&lt;li&gt;“If this pod gets compromised… what can it access?”&lt;/li&gt;
&lt;li&gt;“Can lateral movement happen here?”&lt;/li&gt;
&lt;li&gt;“What is the blast radius?”&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This mindset separates checkbox security from real security engineering.&lt;/p&gt;

&lt;p&gt;Because attackers don’t exploit one thing.&lt;/p&gt;

&lt;p&gt;They chain weaknesses together.&lt;/p&gt;




&lt;h2&gt;
  
  
  🔐 6️⃣ They Protect Secrets Like Production Data
&lt;/h2&gt;

&lt;p&gt;API keys. Tokens. SSH keys. Cloud credentials.&lt;/p&gt;

&lt;p&gt;These are gold mines for attackers.&lt;/p&gt;

&lt;p&gt;Great DevSecOps engineers:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;rotate secrets regularly&lt;/li&gt;
&lt;li&gt;avoid hardcoded credentials&lt;/li&gt;
&lt;li&gt;use secret managers&lt;/li&gt;
&lt;li&gt;enforce least privilege access&lt;/li&gt;
&lt;li&gt;monitor secret exposure continuously&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And most importantly…&lt;/p&gt;

&lt;p&gt;they assume secrets &lt;em&gt;will eventually leak&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;So they design systems that minimize damage when it happens.&lt;/p&gt;

&lt;p&gt;That mindset is mature security engineering.&lt;/p&gt;




&lt;h2&gt;
  
  
  📦 7️⃣ They Scan Containers — But Also Understand Them
&lt;/h2&gt;

&lt;p&gt;Many engineers run container scans without understanding containers themselves.&lt;/p&gt;

&lt;p&gt;Great engineers know:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;how container layers work&lt;/li&gt;
&lt;li&gt;image minimization strategies&lt;/li&gt;
&lt;li&gt;runtime isolation&lt;/li&gt;
&lt;li&gt;capabilities&lt;/li&gt;
&lt;li&gt;namespaces&lt;/li&gt;
&lt;li&gt;root vs non-root execution&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Because real container security is not:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Run scanner and pray.”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;It’s understanding:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;what’s inside the image&lt;/li&gt;
&lt;li&gt;how it behaves at runtime&lt;/li&gt;
&lt;li&gt;what permissions it has&lt;/li&gt;
&lt;li&gt;how attackers may escape it&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That deeper knowledge matters massively in Kubernetes environments.&lt;/p&gt;




&lt;h2&gt;
  
  
  📉 8️⃣ They Reduce Noise Ruthlessly
&lt;/h2&gt;

&lt;p&gt;One of the hardest parts of DevSecOps isn’t finding alerts.&lt;/p&gt;

&lt;p&gt;It’s surviving alert fatigue.&lt;/p&gt;

&lt;p&gt;Great engineers continuously tune:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;SAST rules&lt;/li&gt;
&lt;li&gt;DAST policies&lt;/li&gt;
&lt;li&gt;SIEM alerts&lt;/li&gt;
&lt;li&gt;runtime detections&lt;/li&gt;
&lt;li&gt;vulnerability thresholds&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Because if everything is critical…&lt;/p&gt;

&lt;p&gt;nothing is critical.&lt;/p&gt;

&lt;p&gt;Security systems should help developers focus — not overwhelm them.&lt;/p&gt;

&lt;p&gt;The best DevSecOps engineers know how to balance:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;security&lt;/li&gt;
&lt;li&gt;developer productivity&lt;/li&gt;
&lt;li&gt;operational reality&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That balance is incredibly valuable.&lt;/p&gt;




&lt;h2&gt;
  
  
  🤝 9️⃣ They Build Relationships With Developers
&lt;/h2&gt;

&lt;p&gt;This one changes everything.&lt;/p&gt;

&lt;p&gt;Good DevSecOps engineers enforce policies.&lt;/p&gt;

&lt;p&gt;Great DevSecOps engineers enable developers.&lt;/p&gt;

&lt;p&gt;They don’t become “the security blocker.”&lt;/p&gt;

&lt;p&gt;Instead, they:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;explain risks clearly&lt;/li&gt;
&lt;li&gt;help fix issues&lt;/li&gt;
&lt;li&gt;simplify secure workflows&lt;/li&gt;
&lt;li&gt;educate teams&lt;/li&gt;
&lt;li&gt;create reusable templates&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Because DevSecOps is not only about technology.&lt;/p&gt;

&lt;p&gt;It’s about culture.&lt;/p&gt;

&lt;p&gt;And developers listen to engineers who help them succeed.&lt;/p&gt;




&lt;h2&gt;
  
  
  📚 🔟 They Never Stop Learning
&lt;/h2&gt;

&lt;p&gt;The security world changes ridiculously fast.&lt;/p&gt;

&lt;p&gt;New:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;CVEs&lt;/li&gt;
&lt;li&gt;cloud attack vectors&lt;/li&gt;
&lt;li&gt;supply chain risks&lt;/li&gt;
&lt;li&gt;AI threats&lt;/li&gt;
&lt;li&gt;Kubernetes exploits&lt;/li&gt;
&lt;li&gt;ransomware techniques&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;appear constantly.&lt;/p&gt;

&lt;p&gt;Great DevSecOps engineers stay curious.&lt;/p&gt;

&lt;p&gt;They:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;read incident reports&lt;/li&gt;
&lt;li&gt;study breaches&lt;/li&gt;
&lt;li&gt;experiment in labs&lt;/li&gt;
&lt;li&gt;break things safely&lt;/li&gt;
&lt;li&gt;learn offensive security concepts&lt;/li&gt;
&lt;li&gt;follow cloud-native trends&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And honestly…&lt;/p&gt;

&lt;p&gt;this habit alone may be the biggest differentiator of all.&lt;/p&gt;

&lt;p&gt;Because the engineers who stop learning eventually become outdated.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Final Thoughts
&lt;/h2&gt;

&lt;p&gt;DevSecOps isn’t just:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;running scanners&lt;/li&gt;
&lt;li&gt;writing YAML&lt;/li&gt;
&lt;li&gt;configuring pipelines&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The great engineers think differently.&lt;/p&gt;

&lt;p&gt;They:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;automate relentlessly&lt;/li&gt;
&lt;li&gt;understand systems deeply&lt;/li&gt;
&lt;li&gt;anticipate attack paths&lt;/li&gt;
&lt;li&gt;reduce friction&lt;/li&gt;
&lt;li&gt;learn continuously&lt;/li&gt;
&lt;li&gt;build security into culture&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That’s what separates someone who &lt;em&gt;uses DevSecOps tools&lt;/em&gt;…&lt;/p&gt;

&lt;p&gt;from someone who truly engineers secure systems.&lt;/p&gt;

&lt;p&gt;And in 2026, companies desperately need the second type.&lt;/p&gt;




&lt;h2&gt;
  
  
  💬 What About You?
&lt;/h2&gt;

&lt;p&gt;Which DevSecOps habit do you think matters the most?&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Automation?&lt;/li&gt;
&lt;li&gt;Cloud knowledge?&lt;/li&gt;
&lt;li&gt;Security mindset?&lt;/li&gt;
&lt;li&gt;Communication?&lt;/li&gt;
&lt;li&gt;Continuous learning?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Drop your thoughts below 👇&lt;/p&gt;

</description>
      <category>productivity</category>
      <category>webdev</category>
      <category>devops</category>
      <category>ai</category>
    </item>
    <item>
      <title>Day 2 — Linux Fundamentals</title>
      <dc:creator>Rahul Joshi</dc:creator>
      <pubDate>Wed, 13 May 2026 05:07:30 +0000</pubDate>
      <link>https://forem.com/17j/day-2-linux-fundamentals-4c8h</link>
      <guid>https://forem.com/17j/day-2-linux-fundamentals-4c8h</guid>
      <description>&lt;h2&gt;
  
  
  🐧 Linux Fundamentals Every DevSecOps &amp;amp; Cloud Engineer Should Know
&lt;/h2&gt;

&lt;p&gt;There’s a funny truth in tech:&lt;/p&gt;

&lt;p&gt;You can spend years learning Kubernetes, Docker, Terraform, CI/CD, and cloud platforms…&lt;br&gt;
but sooner or later, everything still comes back to one thing:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Linux.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Servers run on Linux.&lt;br&gt;
Containers run on Linux.&lt;br&gt;
Most cloud systems rely on Linux.&lt;br&gt;
Even modern DevSecOps pipelines silently depend on Linux permissions, users, file systems, and shell commands working correctly.&lt;/p&gt;

&lt;p&gt;And yet many beginners jump directly into “advanced DevOps” without understanding the basics.&lt;/p&gt;

&lt;p&gt;That’s like trying to fly a fighter jet before learning how steering works.&lt;/p&gt;

&lt;p&gt;So in this blog, let’s break down Linux Fundamentals in a practical, beginner-friendly, and industry-focused way.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Github Repo:&lt;/strong&gt; &lt;a href="https://github.com/17J/30-Days-Cloud-DevSecOps-Journey" rel="noopener noreferrer"&gt;https://github.com/17J/30-Days-Cloud-DevSecOps-Journey&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Command Sheet:&lt;/strong&gt; &lt;a href="https://bash-command-sheets-k51c.vercel.app/" rel="noopener noreferrer"&gt;https://bash-command-sheets-k51c.vercel.app/&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;


&lt;h2&gt;
  
  
  🚀 Why Linux Matters So Much
&lt;/h2&gt;

&lt;p&gt;If you enter any of these fields:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;DevOps&lt;/li&gt;
&lt;li&gt;Cloud Engineering&lt;/li&gt;
&lt;li&gt;Cybersecurity&lt;/li&gt;
&lt;li&gt;Site Reliability Engineering (SRE)&lt;/li&gt;
&lt;li&gt;Backend Development&lt;/li&gt;
&lt;li&gt;Platform Engineering&lt;/li&gt;
&lt;li&gt;Kubernetes Administration&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;…Linux becomes unavoidable.&lt;/p&gt;

&lt;p&gt;Most production servers worldwide run Linux because it is:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Stable&lt;/li&gt;
&lt;li&gt;Lightweight&lt;/li&gt;
&lt;li&gt;Secure&lt;/li&gt;
&lt;li&gt;Open-source&lt;/li&gt;
&lt;li&gt;Highly customizable&lt;/li&gt;
&lt;li&gt;Automation friendly&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That’s why companies like:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Google&lt;/li&gt;
&lt;li&gt;Amazon&lt;/li&gt;
&lt;li&gt;Netflix&lt;/li&gt;
&lt;li&gt;Meta&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;all heavily rely on Linux infrastructure.&lt;/p&gt;


&lt;h2&gt;
  
  
  🖥️ Understanding Linux Basics
&lt;/h2&gt;

&lt;p&gt;Linux is an operating system kernel that powers many distributions (distros) like:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Ubuntu&lt;/li&gt;
&lt;li&gt;Debian&lt;/li&gt;
&lt;li&gt;CentOS&lt;/li&gt;
&lt;li&gt;Fedora&lt;/li&gt;
&lt;li&gt;Arch Linux&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Think of Linux as the “engine” and distributions as different car models built around it.&lt;/p&gt;

&lt;p&gt;In DevOps, the most commonly used distro is usually:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Ubuntu Server&lt;/li&gt;
&lt;li&gt;Debian&lt;/li&gt;
&lt;li&gt;RHEL / Rocky Linux&lt;/li&gt;
&lt;/ul&gt;


&lt;h3&gt;
  
  
  📂 Linux File System Explained
&lt;/h3&gt;

&lt;p&gt;One of the first things beginners notice:&lt;/p&gt;

&lt;p&gt;Linux does NOT use drives like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;C:&lt;span class="se"&gt;\&lt;/span&gt;
D:&lt;span class="se"&gt;\&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Instead, Linux starts from a single root directory:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;/
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Everything exists under this root.&lt;/p&gt;




&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ffbimj40jdyx25cfr6g03.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ffbimj40jdyx25cfr6g03.png" alt="Linux File System " width="627" height="315"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  📁 Important Linux Directories
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Directory&lt;/th&gt;
&lt;th&gt;Purpose&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Root directory&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/home&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;User files&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/etc&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Configuration files&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/var&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Logs and variable data&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bin&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Essential commands&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/tmp&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Temporary files&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/root&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Root user home&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/usr&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Applications and utilities&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;/home/rahul/projects
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;means:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;home&lt;/code&gt; directory&lt;/li&gt;
&lt;li&gt;inside it → user &lt;code&gt;rahul&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;inside it → folder &lt;code&gt;projects&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  ⚡ Essential Linux Commands
&lt;/h2&gt;

&lt;h3&gt;
  
  
  📍 1. Check Current Directory
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;pwd&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Output:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;/home/ubuntu
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This tells you where you currently are.&lt;/p&gt;




&lt;h3&gt;
  
  
  📍 2. List Files
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;ls&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Detailed list:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;ls&lt;/span&gt; &lt;span class="nt"&gt;-la&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This shows:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;hidden files&lt;/li&gt;
&lt;li&gt;permissions&lt;/li&gt;
&lt;li&gt;ownership&lt;/li&gt;
&lt;li&gt;timestamps&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  📍 3. Change Directory
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cd&lt;/span&gt; /var/log
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Go back:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cd&lt;/span&gt; ..
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Go to home:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cd&lt;/span&gt; ~
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  📍 4. Create Files &amp;amp; Folders
&lt;/h3&gt;

&lt;p&gt;Create folder:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;mkdir &lt;/span&gt;devops
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Create file:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;touch &lt;/span&gt;notes.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  📍 5. Copy, Move &amp;amp; Delete
&lt;/h3&gt;

&lt;p&gt;Copy:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cp &lt;/span&gt;file.txt backup.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Move:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;mv &lt;/span&gt;old.txt new.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Delete:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;rm &lt;/span&gt;file.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Delete folder recursively:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;rm&lt;/span&gt; &lt;span class="nt"&gt;-rf&lt;/span&gt; foldername
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;⚠️ Be careful with &lt;code&gt;rm -rf&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;One wrong command can destroy an entire server.&lt;/p&gt;

&lt;p&gt;Yes… this has happened in real companies.&lt;/p&gt;




&lt;h2&gt;
  
  
  🔍 Viewing File Content
&lt;/h2&gt;

&lt;p&gt;View file:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cat &lt;/span&gt;file.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Large files:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;less file.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Real-time logs:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;tail&lt;/span&gt; &lt;span class="nt"&gt;-f&lt;/span&gt; app.log
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is extremely common in DevOps troubleshooting.&lt;/p&gt;




&lt;h2&gt;
  
  
  🔐 Linux Permissions Explained
&lt;/h2&gt;

&lt;p&gt;This is where Linux becomes VERY important for security.&lt;/p&gt;

&lt;p&gt;Run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;ls&lt;/span&gt; &lt;span class="nt"&gt;-l&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You may see:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nt"&gt;-rwxr-xr--&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Looks scary at first.&lt;/p&gt;

&lt;p&gt;But it’s simple once broken down.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Permission Structure
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzje85egw4acoc9pea668.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzje85egw4acoc9pea668.png" alt="Permission Demo" width="623" height="359"&gt;&lt;/a&gt;&lt;br&gt;
Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nt"&gt;-rwxr-xr--&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Split it:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;rwx | r-x | r--
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;These represent:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Section&lt;/th&gt;
&lt;th&gt;Meaning&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;First&lt;/td&gt;
&lt;td&gt;Owner permissions&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Second&lt;/td&gt;
&lt;td&gt;Group permissions&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Third&lt;/td&gt;
&lt;td&gt;Others permissions&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  📌 Permission Types
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Symbol&lt;/th&gt;
&lt;th&gt;Meaning&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;r&lt;/td&gt;
&lt;td&gt;Read&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;w&lt;/td&gt;
&lt;td&gt;Write&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;x&lt;/td&gt;
&lt;td&gt;Execute&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  🔧 Changing Permissions
&lt;/h2&gt;

&lt;p&gt;Give execute permission:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;chmod&lt;/span&gt; +x script.sh
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Specific permissions:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;chmod &lt;/span&gt;755 script.sh
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🤔 What is 755?
&lt;/h2&gt;

&lt;p&gt;Numbers represent permissions:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Number&lt;/th&gt;
&lt;th&gt;Permission&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;7&lt;/td&gt;
&lt;td&gt;rwx&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;5&lt;/td&gt;
&lt;td&gt;r-x&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;5&lt;/td&gt;
&lt;td&gt;r-x&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;So:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;755
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;means:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Owner → full access&lt;/li&gt;
&lt;li&gt;Group → read &amp;amp; execute&lt;/li&gt;
&lt;li&gt;Others → read &amp;amp; execute&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This is very common for scripts and applications.&lt;/p&gt;




&lt;h3&gt;
  
  
  👤 Users &amp;amp; Groups in Linux
&lt;/h3&gt;

&lt;p&gt;Linux is a multi-user operating system.&lt;/p&gt;

&lt;p&gt;That means multiple users can work on the same machine securely.&lt;/p&gt;




&lt;h3&gt;
  
  
  👥 Create a User
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;adduser rahul
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Set password and details.&lt;/p&gt;




&lt;h3&gt;
  
  
  👥 Create a Group
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;groupadd developers
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  🔗 Add User to Group
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;usermod &lt;span class="nt"&gt;-aG&lt;/span&gt; developers rahul
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is heavily used in:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;DevOps teams&lt;/li&gt;
&lt;li&gt;Shared servers&lt;/li&gt;
&lt;li&gt;Kubernetes nodes&lt;/li&gt;
&lt;li&gt;CI/CD runners&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  👑 The Root User
&lt;/h2&gt;

&lt;p&gt;Linux has a superuser called:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;root
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Root can do EVERYTHING.&lt;/p&gt;

&lt;p&gt;That’s why production systems usually avoid direct root access.&lt;/p&gt;

&lt;p&gt;Instead, admins use:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;apt update
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This temporarily gives admin privileges.&lt;/p&gt;




&lt;h2&gt;
  
  
  📦 Package Management
&lt;/h2&gt;

&lt;p&gt;Linux installs software using package managers.&lt;/p&gt;

&lt;p&gt;Ubuntu:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;apt &lt;span class="nb"&gt;install &lt;/span&gt;nginx
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;CentOS/RHEL:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;yum &lt;span class="nb"&gt;install &lt;/span&gt;nginx
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;or&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;dnf &lt;span class="nb"&gt;install &lt;/span&gt;nginx
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🌐 Real DevOps Connection
&lt;/h2&gt;

&lt;p&gt;Here’s the reality:&lt;/p&gt;

&lt;p&gt;When CI/CD pipelines fail…&lt;/p&gt;

&lt;p&gt;You often debug Linux.&lt;/p&gt;

&lt;p&gt;When containers crash…&lt;/p&gt;

&lt;p&gt;You inspect Linux logs.&lt;/p&gt;

&lt;p&gt;When Kubernetes breaks…&lt;/p&gt;

&lt;p&gt;You SSH into Linux nodes.&lt;/p&gt;

&lt;p&gt;When cloud servers slow down…&lt;/p&gt;

&lt;p&gt;You monitor Linux processes.&lt;/p&gt;

&lt;p&gt;Linux is not “optional knowledge” anymore.&lt;/p&gt;

&lt;p&gt;It is the foundation layer of modern infrastructure.&lt;/p&gt;




&lt;h2&gt;
  
  
  🔥 Linux Skills That Make You Valuable
&lt;/h2&gt;

&lt;p&gt;Companies LOVE engineers who can:&lt;/p&gt;

&lt;p&gt;✅ Navigate servers confidently&lt;br&gt;
✅ Debug issues quickly&lt;br&gt;
✅ Understand permissions&lt;br&gt;
✅ Manage users securely&lt;br&gt;
✅ Read logs efficiently&lt;br&gt;
✅ Automate shell tasks&lt;br&gt;
✅ Work comfortably in terminal environments&lt;/p&gt;

&lt;p&gt;Because these skills directly impact:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;uptime&lt;/li&gt;
&lt;li&gt;security&lt;/li&gt;
&lt;li&gt;deployments&lt;/li&gt;
&lt;li&gt;incident response&lt;/li&gt;
&lt;li&gt;infrastructure stability&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Some Examples
&lt;/h2&gt;

&lt;h3&gt;
  
  
  🔹 Create users &amp;amp; groups
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;adduser testuser
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  🔹 Change permissions
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;chmod &lt;/span&gt;700 secret.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  🔹 Explore logs
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cd&lt;/span&gt; /var/log
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  🔹 Install software
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;apt &lt;span class="nb"&gt;install &lt;/span&gt;nginx
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  🔹 Create shell scripts
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;#!/bin/bash&lt;/span&gt;
&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Hello Linux"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  💡 Final Thoughts
&lt;/h2&gt;

&lt;p&gt;Most people try to skip Linux fundamentals because they look “basic.”&lt;/p&gt;

&lt;p&gt;But experienced engineers know the truth:&lt;/p&gt;

&lt;p&gt;The stronger your Linux foundation,&lt;br&gt;
the easier DevOps, Cloud, Security, Docker, and Kubernetes become.&lt;/p&gt;

&lt;p&gt;Linux is one of those skills that compounds over time.&lt;/p&gt;

&lt;p&gt;At first, commands feel confusing.&lt;/p&gt;

&lt;p&gt;Then one day, you realize you’re managing servers, automating deployments, debugging production issues, and writing shell scripts without even thinking.&lt;/p&gt;

&lt;p&gt;That’s when Linux stops feeling like an operating system…&lt;/p&gt;

&lt;p&gt;…and starts feeling like a superpower. 🚀&lt;/p&gt;

</description>
      <category>masterclassdevsecops</category>
      <category>linux</category>
      <category>devops</category>
      <category>cloud</category>
    </item>
    <item>
      <title>Day 1 — Introduction to DevOps &amp; DevSecOps</title>
      <dc:creator>Rahul Joshi</dc:creator>
      <pubDate>Tue, 12 May 2026 06:04:09 +0000</pubDate>
      <link>https://forem.com/17j/day-1-introduction-to-devops-devsecops-1m68</link>
      <guid>https://forem.com/17j/day-1-introduction-to-devops-devsecops-1m68</guid>
      <description>&lt;p&gt;A few years ago, software teams had one major goal:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Ship faster.”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Today?&lt;/p&gt;

&lt;p&gt;The goal has changed to:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Ship faster… without breaking security.”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;And that single shift is exactly why the industry moved from &lt;strong&gt;DevOps&lt;/strong&gt; to &lt;strong&gt;DevSecOps&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Modern applications are no longer simple.&lt;br&gt;
A single deployment may include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Containers&lt;/li&gt;
&lt;li&gt;Kubernetes clusters&lt;/li&gt;
&lt;li&gt;CI/CD pipelines&lt;/li&gt;
&lt;li&gt;Cloud infrastructure&lt;/li&gt;
&lt;li&gt;APIs&lt;/li&gt;
&lt;li&gt;Open-source dependencies&lt;/li&gt;
&lt;li&gt;AI integrations&lt;/li&gt;
&lt;li&gt;Infrastructure as Code (IaC)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That means speed alone is not enough anymore.&lt;/p&gt;

&lt;p&gt;Because if your pipeline deploys vulnerable code in seconds…&lt;br&gt;
you’ve simply automated the breach.&lt;/p&gt;

&lt;p&gt;So let’s break this down properly 👇&lt;/p&gt;

&lt;p&gt;📂 GitHub Repository:&lt;br&gt;
&lt;a href="https://github.com/17J/30-Days-Cloud-DevSecOps-Journey" rel="noopener noreferrer"&gt;30 Days Cloud &amp;amp; DevSecOps Journey GitHub Repo&lt;/a&gt;&lt;/p&gt;


&lt;h2&gt;
  
  
  ⚙️ What is DevOps?
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzizlb2fdikormcuby911.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzizlb2fdikormcuby911.png" alt="DevOps Cycle Image" width="666" height="333"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;DevOps is a combination of:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Development (Dev)&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Operations (Ops)&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It’s a culture and engineering practice focused on improving collaboration between developers and operations teams.&lt;/p&gt;

&lt;p&gt;The main goal of DevOps is:&lt;/p&gt;

&lt;p&gt;✅ Faster software delivery&lt;br&gt;
✅ Automation&lt;br&gt;
✅ Continuous Integration &amp;amp; Deployment&lt;br&gt;
✅ Better reliability&lt;br&gt;
✅ Reduced manual work&lt;/p&gt;

&lt;p&gt;Before DevOps, development and operations teams often worked separately.&lt;/p&gt;

&lt;p&gt;Developers would say:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“The code works on my machine.”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Operations teams would respond:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Then why is production down?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Classic problem 😅&lt;/p&gt;

&lt;p&gt;DevOps solved this by introducing automation, collaboration, and shared ownership.&lt;/p&gt;


&lt;h2&gt;
  
  
  🔄 Core Principles of DevOps
&lt;/h2&gt;
&lt;h3&gt;
  
  
  1️⃣ Continuous Integration (CI)
&lt;/h3&gt;

&lt;p&gt;Developers continuously merge code into a shared repository.&lt;/p&gt;

&lt;p&gt;Every commit automatically triggers:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Builds&lt;/li&gt;
&lt;li&gt;Tests&lt;/li&gt;
&lt;li&gt;Validation checks&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Tools commonly used:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;GitHub Actions&lt;/li&gt;
&lt;li&gt;GitLab CI/CD&lt;/li&gt;
&lt;li&gt;Jenkins&lt;/li&gt;
&lt;li&gt;CircleCI&lt;/li&gt;
&lt;/ul&gt;


&lt;h3&gt;
  
  
  2️⃣ Continuous Delivery / Deployment (CD)
&lt;/h3&gt;

&lt;p&gt;Once code passes testing, it can automatically move into staging or production.&lt;/p&gt;

&lt;p&gt;This reduces:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Human error&lt;/li&gt;
&lt;li&gt;Delays&lt;/li&gt;
&lt;li&gt;Deployment friction&lt;/li&gt;
&lt;/ul&gt;


&lt;h3&gt;
  
  
  3️⃣ Infrastructure as Code (IaC)
&lt;/h3&gt;

&lt;p&gt;Infrastructure is managed using code instead of manual setup.&lt;/p&gt;

&lt;p&gt;Examples:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;HashiCorp Terraform&lt;/li&gt;
&lt;li&gt;Red Hat Ansible&lt;/li&gt;
&lt;/ul&gt;


&lt;h3&gt;
  
  
  4️⃣ Monitoring &amp;amp; Observability
&lt;/h3&gt;

&lt;p&gt;Teams continuously monitor systems for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Performance&lt;/li&gt;
&lt;li&gt;Errors&lt;/li&gt;
&lt;li&gt;Downtime&lt;/li&gt;
&lt;li&gt;Resource usage&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Popular tools:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Datadog&lt;/li&gt;
&lt;li&gt;Grafana Labs&lt;/li&gt;
&lt;li&gt;New Relic&lt;/li&gt;
&lt;/ul&gt;


&lt;h2&gt;
  
  
  🔐 What is DevSecOps?
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fg2yyib3etfprhiju9uhh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fg2yyib3etfprhiju9uhh.png" alt="DevSecOps Cycle Image" width="655" height="328"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;DevSecOps stands for:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Development + Security + Operations&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;It extends DevOps by integrating security into every stage of the software lifecycle.&lt;/p&gt;

&lt;p&gt;Instead of security being checked &lt;em&gt;after deployment&lt;/em&gt;, DevSecOps makes security part of the pipeline itself.&lt;/p&gt;

&lt;p&gt;The philosophy becomes:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Security is everyone’s responsibility.”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Not just the security team.&lt;/p&gt;


&lt;h2&gt;
  
  
  🧠 Traditional Security vs DevSecOps
&lt;/h2&gt;

&lt;p&gt;Old security model:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Develop → Deploy → Security Team Checks Later
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Modern DevSecOps model:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Develop → Scan → Test → Secure → Deploy → Monitor
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That difference is massive.&lt;/p&gt;

&lt;p&gt;Because vulnerabilities found late are:&lt;/p&gt;

&lt;p&gt;❌ More expensive&lt;br&gt;
❌ Harder to fix&lt;br&gt;
❌ Riskier in production&lt;/p&gt;


&lt;h2&gt;
  
  
  ⚡ Why DevSecOps Became Necessary
&lt;/h2&gt;

&lt;p&gt;Software delivery became incredibly fast.&lt;/p&gt;

&lt;p&gt;Teams now deploy:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Multiple times per day&lt;/li&gt;
&lt;li&gt;Across cloud-native environments&lt;/li&gt;
&lt;li&gt;Using automated pipelines&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;But attackers also evolved.&lt;/p&gt;

&lt;p&gt;Modern threats include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Supply chain attacks&lt;/li&gt;
&lt;li&gt;Secret leaks&lt;/li&gt;
&lt;li&gt;Vulnerable containers&lt;/li&gt;
&lt;li&gt;Dependency poisoning&lt;/li&gt;
&lt;li&gt;Misconfigured cloud infrastructure&lt;/li&gt;
&lt;li&gt;CI/CD compromise&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Without built-in security, fast delivery becomes dangerous delivery.&lt;/p&gt;


&lt;h2&gt;
  
  
  🛡️ What DevSecOps Adds to DevOps
&lt;/h2&gt;
&lt;h3&gt;
  
  
  1️⃣ Automated Security Scanning
&lt;/h3&gt;

&lt;p&gt;Security checks run automatically inside pipelines.&lt;/p&gt;

&lt;p&gt;Examples:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Secret scanning&lt;/li&gt;
&lt;li&gt;Dependency scanning&lt;/li&gt;
&lt;li&gt;Container scanning&lt;/li&gt;
&lt;li&gt;Static code analysis&lt;/li&gt;
&lt;li&gt;IaC security scanning&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Popular tools include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Snyk&lt;/li&gt;
&lt;li&gt;SonarSource&lt;/li&gt;
&lt;li&gt;Aqua Security&lt;/li&gt;
&lt;li&gt;Checkmarx&lt;/li&gt;
&lt;/ul&gt;


&lt;h3&gt;
  
  
  2️⃣ Shift-Left Security
&lt;/h3&gt;

&lt;p&gt;“Shift Left” means moving security earlier into development.&lt;/p&gt;

&lt;p&gt;Instead of finding vulnerabilities in production:&lt;/p&gt;

&lt;p&gt;✅ Detect them during coding&lt;br&gt;
✅ Detect them during pull requests&lt;br&gt;
✅ Detect them during CI builds&lt;/p&gt;

&lt;p&gt;This dramatically reduces remediation cost.&lt;/p&gt;


&lt;h3&gt;
  
  
  3️⃣ Secure CI/CD Pipelines
&lt;/h3&gt;

&lt;p&gt;Pipelines themselves are now protected.&lt;/p&gt;

&lt;p&gt;Because attackers increasingly target:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Build systems&lt;/li&gt;
&lt;li&gt;CI runners&lt;/li&gt;
&lt;li&gt;Deployment tokens&lt;/li&gt;
&lt;li&gt;GitHub Actions workflows&lt;/li&gt;
&lt;li&gt;Artifact registries&lt;/li&gt;
&lt;/ul&gt;


&lt;h2&gt;
  
  
  ⚔️ DevOps vs DevSecOps
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Feature&lt;/th&gt;
&lt;th&gt;DevOps&lt;/th&gt;
&lt;th&gt;DevSecOps&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Main Focus&lt;/td&gt;
&lt;td&gt;Speed &amp;amp; Automation&lt;/td&gt;
&lt;td&gt;Speed + Security + Automation&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Security Timing&lt;/td&gt;
&lt;td&gt;Often later&lt;/td&gt;
&lt;td&gt;Integrated early&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Responsibility&lt;/td&gt;
&lt;td&gt;Dev + Ops&lt;/td&gt;
&lt;td&gt;Dev + Sec + Ops&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Pipeline Checks&lt;/td&gt;
&lt;td&gt;Build &amp;amp; Test&lt;/td&gt;
&lt;td&gt;Build + Test + Security&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Goal&lt;/td&gt;
&lt;td&gt;Faster delivery&lt;/td&gt;
&lt;td&gt;Secure faster delivery&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;


&lt;h2&gt;
  
  
  🔥 Why Security Matters in CI/CD
&lt;/h2&gt;

&lt;p&gt;This is where things get serious.&lt;/p&gt;

&lt;p&gt;Your CI/CD pipeline is basically the “factory” producing software.&lt;/p&gt;

&lt;p&gt;If attackers compromise the factory…&lt;/p&gt;

&lt;p&gt;they compromise &lt;em&gt;everything&lt;/em&gt;.&lt;/p&gt;


&lt;h2&gt;
  
  
  🚨 Real Risks Inside CI/CD
&lt;/h2&gt;
&lt;h3&gt;
  
  
  Exposed Secrets
&lt;/h3&gt;

&lt;p&gt;Hardcoded API keys or cloud credentials inside repositories.&lt;/p&gt;

&lt;p&gt;This is still one of the most common breaches.&lt;/p&gt;


&lt;h3&gt;
  
  
  Vulnerable Dependencies
&lt;/h3&gt;

&lt;p&gt;Developers install open-source packages daily.&lt;/p&gt;

&lt;p&gt;One compromised dependency can infect the entire application.&lt;/p&gt;

&lt;p&gt;This became widely discussed after supply chain attacks like:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;SolarWinds cyberattack&lt;/li&gt;
&lt;li&gt;Log4Shell&lt;/li&gt;
&lt;/ul&gt;


&lt;h3&gt;
  
  
  🐳 Insecure Containers
&lt;/h3&gt;

&lt;p&gt;A container image may include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Outdated libraries&lt;/li&gt;
&lt;li&gt;Root privileges&lt;/li&gt;
&lt;li&gt;Critical CVEs&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Without scanning, vulnerable containers reach production easily.&lt;/p&gt;


&lt;h3&gt;
  
  
  ☁️ Cloud Misconfigurations
&lt;/h3&gt;

&lt;p&gt;Simple mistakes like:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Public S3 buckets&lt;/li&gt;
&lt;li&gt;Open databases&lt;/li&gt;
&lt;li&gt;Weak IAM permissions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;can expose entire infrastructures.&lt;/p&gt;


&lt;h3&gt;
  
  
  🔄 Why Automation Matters
&lt;/h3&gt;

&lt;p&gt;Manual security reviews cannot keep up with modern deployment speed.&lt;/p&gt;

&lt;p&gt;A team deploying 50 times daily cannot rely on:&lt;/p&gt;

&lt;p&gt;❌ Spreadsheets&lt;br&gt;
❌ Manual approvals&lt;br&gt;
❌ Occasional audits&lt;/p&gt;

&lt;p&gt;Security must become automated.&lt;/p&gt;

&lt;p&gt;That’s the heart of DevSecOps.&lt;/p&gt;


&lt;h3&gt;
  
  
  🧪 Typical DevSecOps CI/CD Pipeline
&lt;/h3&gt;

&lt;p&gt;A modern secure pipeline often looks like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Developer Pushes Code
        ↓
CI Build Starts
        ↓
Static Code Analysis
        ↓
Dependency Scan
        ↓
Secret Scan
        ↓
Container Scan
        ↓
IaC Security Check
        ↓
Automated Testing
        ↓
Deployment
        ↓
Runtime Monitoring
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Security exists at every layer.&lt;/p&gt;




&lt;h2&gt;
  
  
  📈 Benefits of DevSecOps
&lt;/h2&gt;

&lt;h3&gt;
  
  
  ✅ Faster Vulnerability Detection
&lt;/h3&gt;

&lt;p&gt;Issues are caught before production.&lt;/p&gt;




&lt;h3&gt;
  
  
  ✅ Lower Breach Risk
&lt;/h3&gt;

&lt;p&gt;Automated scanning reduces human oversight gaps.&lt;/p&gt;




&lt;h3&gt;
  
  
  ✅ Better Compliance
&lt;/h3&gt;

&lt;p&gt;Helps organizations align with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;SOC2&lt;/li&gt;
&lt;li&gt;ISO 27001&lt;/li&gt;
&lt;li&gt;PCI-DSS&lt;/li&gt;
&lt;li&gt;HIPAA&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  ✅ Improved Developer Awareness
&lt;/h3&gt;

&lt;p&gt;Developers become more security-conscious over time.&lt;/p&gt;




&lt;h2&gt;
  
  
  🤖 AI Is Changing DevSecOps Too
&lt;/h2&gt;

&lt;p&gt;AI-powered tools now help with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Vulnerability prioritization&lt;/li&gt;
&lt;li&gt;Threat detection&lt;/li&gt;
&lt;li&gt;Misconfiguration analysis&lt;/li&gt;
&lt;li&gt;Automated remediation suggestions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Modern platforms increasingly combine:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;AI&lt;/li&gt;
&lt;li&gt;Observability&lt;/li&gt;
&lt;li&gt;Runtime security&lt;/li&gt;
&lt;li&gt;Automated policy enforcement&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;into one ecosystem.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Final Thoughts
&lt;/h2&gt;

&lt;p&gt;DevOps changed how software is delivered.&lt;/p&gt;

&lt;p&gt;DevSecOps changed how software is protected.&lt;/p&gt;

&lt;p&gt;And in today’s world, speed without security is a liability.&lt;/p&gt;

&lt;p&gt;Because modern attackers don’t wait for yearly audits anymore.&lt;/p&gt;

&lt;p&gt;They target:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Pipelines&lt;/li&gt;
&lt;li&gt;Dependencies&lt;/li&gt;
&lt;li&gt;Containers&lt;/li&gt;
&lt;li&gt;Cloud infrastructure&lt;/li&gt;
&lt;li&gt;Secrets&lt;/li&gt;
&lt;li&gt;Automation systems&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That’s why security inside CI/CD is no longer “optional.”&lt;/p&gt;

&lt;p&gt;It’s part of the deployment process itself.&lt;/p&gt;

&lt;p&gt;The companies succeeding in 2026 are not just the fastest.&lt;/p&gt;

&lt;p&gt;They are the ones that can:&lt;/p&gt;

&lt;p&gt;✅ Build fast&lt;br&gt;
✅ Deploy fast&lt;br&gt;
✅ Recover fast&lt;br&gt;
✅ Stay secure while doing all of it&lt;/p&gt;

&lt;p&gt;And that’s the real evolution from DevOps to DevSecOps.&lt;/p&gt;

</description>
      <category>masterclassdevsecops</category>
      <category>tutorial</category>
      <category>devsecops</category>
      <category>cloud</category>
    </item>
    <item>
      <title>🚀 30 Days Cloud &amp; DevSecOps Journey</title>
      <dc:creator>Rahul Joshi</dc:creator>
      <pubDate>Mon, 11 May 2026 12:47:46 +0000</pubDate>
      <link>https://forem.com/17j/30-days-cloud-devsecops-journey-268a</link>
      <guid>https://forem.com/17j/30-days-cloud-devsecops-journey-268a</guid>
      <description>&lt;p&gt;The cloud world is evolving fast.&lt;br&gt;
DevOps is no longer enough. Security is no longer optional.&lt;/p&gt;

&lt;p&gt;That’s exactly why I’m starting this &lt;strong&gt;30 Days Cloud &amp;amp; DevSecOps Journey&lt;/strong&gt; — building publicly while learning cloud infrastructure, automation, Kubernetes, CI/CD, and security engineering.&lt;/p&gt;

&lt;p&gt;For the next 30 days, I’ll be documenting everything on Dev.to 🚀&lt;/p&gt;

&lt;p&gt;📂 GitHub Repository:&lt;br&gt;
&lt;a href="https://github.com/17J/30-Days-Cloud-DevSecOps-Journey" rel="noopener noreferrer"&gt;30 Days Cloud &amp;amp; DevSecOps Journey GitHub Repo&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  🎯 Why I’m Doing This
&lt;/h2&gt;

&lt;p&gt;I wanted a structured path to learn:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Cloud Computing&lt;/li&gt;
&lt;li&gt;AWS&lt;/li&gt;
&lt;li&gt;Docker &amp;amp; Kubernetes&lt;/li&gt;
&lt;li&gt;CI/CD Pipelines&lt;/li&gt;
&lt;li&gt;DevSecOps&lt;/li&gt;
&lt;li&gt;Infrastructure as Code&lt;/li&gt;
&lt;li&gt;Monitoring &amp;amp; Observability&lt;/li&gt;
&lt;li&gt;Security Automation&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  📚 What This Journey Covers
&lt;/h2&gt;

&lt;p&gt;Over the next 30 days, I’ll be creating and building around:&lt;/p&gt;

&lt;h2&gt;
  
  
  ☁️ Cloud &amp;amp; AWS
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;IAM&lt;/li&gt;
&lt;li&gt;S3&lt;/li&gt;
&lt;li&gt;VPC&lt;/li&gt;
&lt;li&gt;EC2&lt;/li&gt;
&lt;li&gt;Lambda&lt;/li&gt;
&lt;li&gt;CloudWatch&lt;/li&gt;
&lt;li&gt;Billing &amp;amp; Cost Optimization&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  🐳 Containers &amp;amp; Kubernetes
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Docker&lt;/li&gt;
&lt;li&gt;Dockerfiles&lt;/li&gt;
&lt;li&gt;Kubernetes Fundamentals&lt;/li&gt;
&lt;li&gt;EKS&lt;/li&gt;
&lt;li&gt;Helm&lt;/li&gt;
&lt;li&gt;Kubernetes Security&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  🔐 DevSecOps &amp;amp; Security
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;SAST&lt;/li&gt;
&lt;li&gt;DAST&lt;/li&gt;
&lt;li&gt;SCA&lt;/li&gt;
&lt;li&gt;Container Security&lt;/li&gt;
&lt;li&gt;Runtime Security&lt;/li&gt;
&lt;li&gt;Secrets Management&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  ⚙️ CI/CD &amp;amp; Automation
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;GitHub Actions&lt;/li&gt;
&lt;li&gt;Secure Pipelines&lt;/li&gt;
&lt;li&gt;Bash Scripting&lt;/li&gt;
&lt;li&gt;Terraform&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  📊 Monitoring &amp;amp; Observability
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Prometheus&lt;/li&gt;
&lt;li&gt;Grafana&lt;/li&gt;
&lt;li&gt;Logs &amp;amp; Alerts&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🛠️ Tools I’ll Use
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;AWS&lt;/li&gt;
&lt;li&gt;Docker&lt;/li&gt;
&lt;li&gt;Kubernetes&lt;/li&gt;
&lt;li&gt;Terraform&lt;/li&gt;
&lt;li&gt;GitHub Actions&lt;/li&gt;
&lt;li&gt;Snyk&lt;/li&gt;
&lt;li&gt;SonarQube&lt;/li&gt;
&lt;li&gt;OWASP ZAP&lt;/li&gt;
&lt;li&gt;Trivy&lt;/li&gt;
&lt;li&gt;Falco&lt;/li&gt;
&lt;li&gt;Kyverno&lt;/li&gt;
&lt;li&gt;HashiCorp Vault&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🚀 End Goal
&lt;/h2&gt;

&lt;p&gt;By the end of these 30 days:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Build secure CI/CD pipelines&lt;/li&gt;
&lt;li&gt;Deploy cloud-native applications&lt;/li&gt;
&lt;li&gt;Improve Kubernetes &amp;amp; AWS skills&lt;/li&gt;
&lt;li&gt;Learn real-world DevSecOps practices&lt;/li&gt;
&lt;li&gt;Become more confident in cloud security &amp;amp; automation&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🔥 Let’s See Where This Goes
&lt;/h2&gt;

&lt;p&gt;If you’re interested in Cloud, AWS, DevOps, or DevSecOps — feel free to join the journey 🚀&lt;/p&gt;

&lt;p&gt;Day 1 drops tomorrow 👀&lt;/p&gt;




&lt;h2&gt;
  
  
  ⚠️ Disclaimer
&lt;/h2&gt;

&lt;p&gt;This journey is not enough to fully master DevSecOps in 30 days.&lt;/p&gt;

&lt;p&gt;DevSecOps is a vast field that requires continuous learning, hands-on practice, real-world experience, and deep understanding of security, cloud, automation, and infrastructure.&lt;/p&gt;

&lt;p&gt;This journey is simply a starting point to build strong fundamentals, improve consistency, and gain practical exposure to modern Cloud &amp;amp; DevSecOps workflows.&lt;/p&gt;

&lt;p&gt;The goal is to learn step-by-step, build projects, and grow over time — not to become an expert overnight 🚀&lt;/p&gt;

</description>
      <category>aws</category>
      <category>cloud</category>
      <category>tutorial</category>
      <category>masterclassdevsecops</category>
    </item>
    <item>
      <title>🚨 I Secured My Compromised AWS Account : Here’s the Incident Response Playbook</title>
      <dc:creator>Rahul Joshi</dc:creator>
      <pubDate>Tue, 05 May 2026 11:44:06 +0000</pubDate>
      <link>https://forem.com/17j/i-secured-my-compromised-aws-account-heres-the-incident-response-playbook-bn4</link>
      <guid>https://forem.com/17j/i-secured-my-compromised-aws-account-heres-the-incident-response-playbook-bn4</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;“It started with a small billing spike… and ended with an AWS Abuse Report.”&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;One morning, I noticed something unusual in my AWS billing dashboard.&lt;/p&gt;

&lt;p&gt;At first glance, it didn’t look huge — around &lt;strong&gt;$20&lt;/strong&gt;.&lt;br&gt;
But something felt off.&lt;/p&gt;

&lt;h3&gt;
  
  
  ⚠️ The Red Flag
&lt;/h3&gt;

&lt;p&gt;When I checked deeper:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Most charges were from &lt;strong&gt;data transfer&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Traffic originated from &lt;strong&gt;ap-south-1 (Mumbai)&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Data was being sent to &lt;strong&gt;Middle East (Bahrain)&lt;/strong&gt; region&lt;/li&gt;
&lt;li&gt;And the scary part…&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;👉 &lt;strong&gt;This activity happened at night — when I wasn’t even using AWS&lt;/strong&gt;&lt;/p&gt;




&lt;h3&gt;
  
  
  💣 Then Came the Real Shock
&lt;/h3&gt;

&lt;p&gt;During the same time window…&lt;/p&gt;

&lt;p&gt;I received an &lt;strong&gt;AWS Abuse Report email&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;It said:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;My EC2 instance was involved in &lt;strong&gt;suspicious activity&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Possibly &lt;strong&gt;Denial of Service (DoS)-like behavior&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;AWS warned my environment might be &lt;strong&gt;compromised&lt;/strong&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;👉 That’s when it was clear:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;This wasn’t just billing. This was an active compromise.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  ⚠️ Phase 0: What Actually Happened
&lt;/h2&gt;

&lt;h3&gt;
  
  
  📊 Key Indicators:
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;~209 GB data transfer to Bahrain&lt;/li&gt;
&lt;li&gt;Unexpected outbound traffic charges&lt;/li&gt;
&lt;li&gt;Activity during inactive hours&lt;/li&gt;
&lt;li&gt;AWS Abuse Report notification&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;💡 &lt;strong&gt;Interpretation:&lt;/strong&gt;&lt;br&gt;
This strongly indicates:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Your instance was likely used as a &lt;strong&gt;bot / relay server&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Or part of &lt;strong&gt;malicious traffic / scanning / DoS activity&lt;/strong&gt;
&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🛑 Phase 1: Immediate Containment
&lt;/h2&gt;

&lt;h3&gt;
  
  
  🔒 Step 1: Lock Access
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Changed root password&lt;/li&gt;
&lt;li&gt;Verified MFA was already enabled and re-authenticated all sessions to ensure no unauthorized access persisted.&lt;/li&gt;
&lt;li&gt;Logged out all sessions&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  🔐 Step 2: Kill Entry Points
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Revoked all IAM access keys&lt;/li&gt;
&lt;li&gt;Deleted unknown users (if any)&lt;/li&gt;
&lt;li&gt;Checked roles for misuse&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  💻 Step 3: Stop the Attack Source
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Terminated the EC2 instance (important)&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;Stopped all suspicious services&lt;/li&gt;
&lt;li&gt;Restricted outbound traffic in Security Groups&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;💡 In your case:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;The EC2 instance itself was the attack vector.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  🔍 Phase 2: Investigation
&lt;/h2&gt;

&lt;h3&gt;
  
  
  📜 What I Checked:
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;CloudTrail logs&lt;/li&gt;
&lt;li&gt;VPC Flow Logs (for traffic pattern)&lt;/li&gt;
&lt;li&gt;EC2 instance activity&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  🔎 Findings:
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;High outbound traffic to external IPs&lt;/li&gt;
&lt;li&gt;Data routed from Mumbai → Bahrain&lt;/li&gt;
&lt;li&gt;Pattern matched &lt;strong&gt;automated traffic behavior&lt;/strong&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;💡 Most likely cause:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Compromised EC2 (open ports / weak SSH / exposed key)&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🧹 Phase 3: Eradication
&lt;/h2&gt;

&lt;h3&gt;
  
  
  🔥 Actions Taken:
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Terminated compromised EC2&lt;/li&gt;
&lt;li&gt;Removed unused security group rules&lt;/li&gt;
&lt;li&gt;Closed open ports (like 0.0.0.0/0 on SSH)&lt;/li&gt;
&lt;li&gt;Rotated all credentials&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  🔐 Security Fixes:
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Disabled password-based SSH&lt;/li&gt;
&lt;li&gt;Enforced key-based login only&lt;/li&gt;
&lt;li&gt;Removed unnecessary public access&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🛡️ Phase 4: Recovery &amp;amp; Hardening
&lt;/h2&gt;

&lt;h3&gt;
  
  
  ✅ What I Implemented:
&lt;/h3&gt;

&lt;h4&gt;
  
  
  1. Strict Security Groups
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;No open ports to the world&lt;/li&gt;
&lt;li&gt;Only whitelisted IPs&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  2. Monitoring Enabled
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;CloudWatch alerts&lt;/li&gt;
&lt;li&gt;Billing alarms&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  3. GuardDuty Turned On
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;Real-time threat detection&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  4. IAM Hardening
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;Least privilege roles&lt;/li&gt;
&lt;li&gt;No long-term access keys&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  📧 AWS Abuse Report: What It Meant
&lt;/h2&gt;

&lt;p&gt;That email was critical.&lt;/p&gt;

&lt;p&gt;It basically confirmed:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Your infrastructure was being &lt;strong&gt;misused&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;AWS had detected &lt;strong&gt;malicious patterns&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Action was required immediately&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;💡 Important:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Ignoring this email can lead to &lt;strong&gt;account suspension&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  ⚔️ Final Playbook (Based on Real Incident)
&lt;/h2&gt;

&lt;p&gt;If you see:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Unexpected data transfer&lt;/li&gt;
&lt;li&gt;Unknown regions involved&lt;/li&gt;
&lt;li&gt;AWS abuse email&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;👉 Do THIS immediately:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Terminate suspicious EC2&lt;/li&gt;
&lt;li&gt;Revoke all access keys&lt;/li&gt;
&lt;li&gt;Enable MFA&lt;/li&gt;
&lt;li&gt;Check CloudTrail&lt;/li&gt;
&lt;li&gt;Lock down Security Groups&lt;/li&gt;
&lt;li&gt;Rotate secrets&lt;/li&gt;
&lt;li&gt;Enable GuardDuty&lt;/li&gt;
&lt;/ol&gt;




&lt;h2&gt;
  
  
  🧠 Real Lesson
&lt;/h2&gt;

&lt;blockquote&gt;
&lt;p&gt;“It wasn’t a hack of AWS… it was a misconfigured EC2.”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Most likely reasons:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Open SSH port (0.0.0.0/0)&lt;/li&gt;
&lt;li&gt;Weak credentials or leaked key&lt;/li&gt;
&lt;li&gt;No monitoring in place&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🔥 Final Thought
&lt;/h2&gt;

&lt;p&gt;This incident cost me:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Money 💸&lt;/li&gt;
&lt;li&gt;Time ⏱️&lt;/li&gt;
&lt;li&gt;Stress 😓&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;But it gave me something more valuable:&lt;/p&gt;

&lt;p&gt;👉 &lt;strong&gt;Real-world cloud security experience&lt;/strong&gt;&lt;/p&gt;

</description>
      <category>aws</category>
      <category>ai</category>
      <category>devops</category>
      <category>security</category>
    </item>
    <item>
      <title>🤖 Agentic Security: Your AI Got Autonomy. Did Your Security Catch Up?</title>
      <dc:creator>Rahul Joshi</dc:creator>
      <pubDate>Fri, 01 May 2026 12:59:51 +0000</pubDate>
      <link>https://forem.com/17j/agentic-security-your-ai-got-autonomy-did-your-security-catch-up-3leg</link>
      <guid>https://forem.com/17j/agentic-security-your-ai-got-autonomy-did-your-security-catch-up-3leg</guid>
      <description>&lt;p&gt;Let me set a scene.&lt;/p&gt;

&lt;p&gt;You deploy an AI agent to handle your customer data pipeline. It calls APIs, queries databases, writes files, even spawns subtasks. It’s fast. Efficient. Your manager is thrilled.&lt;/p&gt;

&lt;p&gt;Then someone slips a malicious instruction inside a CSV file.&lt;/p&gt;

&lt;p&gt;Your agent reads it… trusts it… and exports 45,000 customer records to an attacker-controlled endpoint.&lt;/p&gt;

&lt;p&gt;The agent didn’t break.&lt;br&gt;
It didn’t hallucinate.&lt;br&gt;
It did exactly what it was designed to do—just for the wrong person.&lt;/p&gt;

&lt;p&gt;This isn’t sci-fi. Variations of this pattern have already shown up in real-world enterprise environments.&lt;/p&gt;

&lt;p&gt;Welcome to &lt;strong&gt;agentic security&lt;/strong&gt;.&lt;/p&gt;


&lt;h2&gt;
  
  
  🧠 What “agentic AI” actually means
&lt;/h2&gt;

&lt;p&gt;Traditional AI:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You ask → it answers&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Agentic AI:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;It &lt;strong&gt;decides&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;It &lt;strong&gt;plans&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;It &lt;strong&gt;acts&lt;/strong&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These systems:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Use tools (APIs, DBs, file systems)&lt;/li&gt;
&lt;li&gt;Maintain memory across sessions&lt;/li&gt;
&lt;li&gt;Execute multi-step workflows&lt;/li&gt;
&lt;li&gt;Collaborate with other agents&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This isn’t a chatbot anymore.&lt;/p&gt;

&lt;p&gt;It’s a &lt;strong&gt;system actor with autonomy&lt;/strong&gt;.&lt;/p&gt;


&lt;h2&gt;
  
  
  📊 The reality check
&lt;/h2&gt;

&lt;p&gt;Recent industry surveys and enterprise reports paint a pretty uncomfortable picture:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;~70% of enterprises are experimenting with or deploying AI agents&lt;/li&gt;
&lt;li&gt;&amp;lt;25% have meaningful visibility into what those agents are doing&lt;/li&gt;
&lt;li&gt;Continuous monitoring of agent interactions is still rare (~15–20%)&lt;/li&gt;
&lt;li&gt;A majority of teams report &lt;strong&gt;unexpected or unauthorized agent actions&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Logging and auditability remain one of the top unsolved problems&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And the big one:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Most teams are deploying agents faster than they can secure them.&lt;/p&gt;
&lt;/blockquote&gt;


&lt;h2&gt;
  
  
  🚨 Why your existing security model breaks
&lt;/h2&gt;

&lt;p&gt;Your current stack—SIEM, EDR, alerts—is built around:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;human behavior&lt;/li&gt;
&lt;li&gt;predictable workflows&lt;/li&gt;
&lt;li&gt;discrete events&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Agentic systems break all three.&lt;/p&gt;

&lt;p&gt;An agent can:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;execute 10,000 “valid” actions in sequence&lt;/li&gt;
&lt;li&gt;follow instructions that &lt;em&gt;look legitimate&lt;/em&gt;
&lt;/li&gt;
&lt;li&gt;operate across tools, memory, and time&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;From the outside, everything looks normal.&lt;/p&gt;

&lt;p&gt;From the inside, it could be a fully automated breach.&lt;/p&gt;


&lt;h2&gt;
  
  
  🧩 Where things go wrong (the real attack surface)
&lt;/h2&gt;

&lt;p&gt;Here’s a simple mental model:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;User Input → Agent Core → Tools / APIs
                   ↕
                Memory
                   ↕
            Other Agents (A2A)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Every arrow is an attack surface.&lt;/p&gt;




&lt;h2&gt;
  
  
  ⚠️ The Big Six threats
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. Memory Poisoning
&lt;/h3&gt;

&lt;p&gt;What happens:&lt;br&gt;
An attacker injects malicious context into memory that influences future decisions.&lt;/p&gt;

&lt;p&gt;Real-world symptom:&lt;br&gt;
Agent starts making consistently wrong or risky decisions based on past context.&lt;/p&gt;

&lt;p&gt;How to detect it:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Track memory writes using tracing tools like:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;LangSmith&lt;/li&gt;
&lt;li&gt;OpenTelemetry&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;Log memory diffs:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;before vs after each interaction&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;Add anomaly detection:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;sudden change in memory patterns → alert&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;




&lt;h3&gt;
  
  
  2. Tool Misuse
&lt;/h3&gt;

&lt;p&gt;What happens:&lt;br&gt;
Agent uses legitimate tools in unintended ways.&lt;/p&gt;

&lt;p&gt;Example:&lt;br&gt;
“Export filtered data” → becomes “export everything”&lt;/p&gt;

&lt;p&gt;How to detect it:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Runtime monitoring with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Falco → detect suspicious system/API calls&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;API-level logging via:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Kong Gateway&lt;/li&gt;
&lt;li&gt;AWS CloudTrail&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;Define rules:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;“Agent X should never call bulk export endpoint”&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;




&lt;h3&gt;
  
  
  3. Goal Hijacking
&lt;/h3&gt;

&lt;p&gt;What happens:&lt;br&gt;
Agent’s objective is subtly altered via input or context.&lt;/p&gt;

&lt;p&gt;How to detect it:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Trace reasoning chains using:

&lt;ul&gt;
&lt;li&gt;LangSmith&lt;/li&gt;
&lt;li&gt;Weights &amp;amp; Biases&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;Compare:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;original goal vs executed actions&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;Add policy validation:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;enforce allowed intents using engines like:&lt;/li&gt;
&lt;li&gt;Open Policy Agent&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;




&lt;h3&gt;
  
  
  4. Privilege Escalation
&lt;/h3&gt;

&lt;p&gt;What happens:&lt;br&gt;
Agent operates with excessive permissions.&lt;/p&gt;

&lt;p&gt;How to detect it:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;IAM monitoring via:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;AWS IAM&lt;/li&gt;
&lt;li&gt;Azure Active Directory&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;Audit logs:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;privilege usage vs expected scope&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;Alert on:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;role assumption spikes&lt;/li&gt;
&lt;li&gt;access to sensitive resources&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;




&lt;h3&gt;
  
  
  5. Supply Chain Attacks
&lt;/h3&gt;

&lt;p&gt;What happens:&lt;br&gt;
Malicious models, packages, or integrations get loaded.&lt;/p&gt;

&lt;p&gt;How to detect it:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Scan dependencies using:

&lt;ul&gt;
&lt;li&gt;Snyk&lt;/li&gt;
&lt;li&gt;Dependabot&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;Static analysis:

&lt;ul&gt;
&lt;li&gt;SonarQube&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;Runtime validation:

&lt;ul&gt;
&lt;li&gt;hash verification of models/plugins&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;




&lt;h3&gt;
  
  
  6. Agent-to-Agent (A2A) Trust Abuse
&lt;/h3&gt;

&lt;p&gt;What happens:&lt;br&gt;
One agent manipulates another through hidden instructions.&lt;/p&gt;

&lt;p&gt;How to detect it:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Trace inter-agent communication:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Jaeger&lt;/li&gt;
&lt;li&gt;OpenTelemetry&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;Log:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;message payloads between agents&lt;/li&gt;
&lt;li&gt;tool calls triggered downstream&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;Detect:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;unexpected cascades of actions&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;




&lt;h2&gt;
  
  
  🔁 Multi-turn attacks are the real problem
&lt;/h2&gt;

&lt;p&gt;Single prompt attacks are old news.&lt;/p&gt;

&lt;p&gt;What’s working now:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;slow manipulation&lt;/li&gt;
&lt;li&gt;context shaping&lt;/li&gt;
&lt;li&gt;multi-step influence&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Across multiple turns, attackers can:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;bypass guardrails&lt;/li&gt;
&lt;li&gt;reshape agent goals&lt;/li&gt;
&lt;li&gt;trigger unsafe actions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Per-request filtering isn’t enough anymore.&lt;/p&gt;

&lt;p&gt;Security has to persist across:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;sessions&lt;/li&gt;
&lt;li&gt;memory&lt;/li&gt;
&lt;li&gt;workflows&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🔌 MCP: the next big risk layer
&lt;/h2&gt;

&lt;p&gt;Model Context Protocol (MCP) is becoming the standard way to connect agents to tools.&lt;/p&gt;

&lt;p&gt;That’s great for developers.&lt;/p&gt;

&lt;p&gt;Also… a massive expansion of the attack surface.&lt;/p&gt;

&lt;p&gt;Common issues emerging:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;overprivileged tool access&lt;/li&gt;
&lt;li&gt;hardcoded credentials (still!)&lt;/li&gt;
&lt;li&gt;tool poisoning&lt;/li&gt;
&lt;li&gt;unsafe execution environments&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Think of MCP like USB for AI.&lt;/p&gt;

&lt;p&gt;And remember how secure USB devices used to be? 😬&lt;/p&gt;




&lt;h2&gt;
  
  
  🛠️ What you should actually do
&lt;/h2&gt;

&lt;p&gt;Let’s keep this practical.&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Enforce least privilege
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Scope API keys tightly&lt;/li&gt;
&lt;li&gt;Separate read/write capabilities&lt;/li&gt;
&lt;li&gt;Avoid “god-mode” agents&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If an agent only needs to read → don’t let it write.&lt;/p&gt;




&lt;h3&gt;
  
  
  2. Make actions observable
&lt;/h3&gt;

&lt;p&gt;You need:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;full execution traces&lt;/li&gt;
&lt;li&gt;tool call logs&lt;/li&gt;
&lt;li&gt;decision tracking&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you can’t answer:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Why did the agent do this?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;You have a problem.&lt;/p&gt;




&lt;h3&gt;
  
  
  3. Monitor agent interactions
&lt;/h3&gt;

&lt;p&gt;Track:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;which agents talk to which&lt;/li&gt;
&lt;li&gt;what data flows between them&lt;/li&gt;
&lt;li&gt;how authority is delegated&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Most teams are blind here.&lt;/p&gt;




&lt;h3&gt;
  
  
  4. Add policy layers
&lt;/h3&gt;

&lt;p&gt;Use:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;rule engines (like OPA-style policies)&lt;/li&gt;
&lt;li&gt;allow/deny lists for tool usage&lt;/li&gt;
&lt;li&gt;contextual validation before execution&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Don’t rely on the model to self-regulate.&lt;/p&gt;




&lt;h3&gt;
  
  
  5. Validate memory
&lt;/h3&gt;

&lt;p&gt;Treat memory like user input:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;sanitize it&lt;/li&gt;
&lt;li&gt;validate it&lt;/li&gt;
&lt;li&gt;expire it when needed&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Persistent context = persistent risk.&lt;/p&gt;




&lt;h3&gt;
  
  
  6. Treat agents like insiders
&lt;/h3&gt;

&lt;p&gt;Not malicious.&lt;/p&gt;

&lt;p&gt;But:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;trusted&lt;/li&gt;
&lt;li&gt;privileged&lt;/li&gt;
&lt;li&gt;and easily manipulated&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That’s exactly what insider threat models are built for.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Final thought
&lt;/h2&gt;

&lt;p&gt;We built agents to automate work.&lt;/p&gt;

&lt;p&gt;But in doing that, we also automated:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;trust&lt;/li&gt;
&lt;li&gt;access&lt;/li&gt;
&lt;li&gt;decision-making&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And we didn’t redesign security for any of it.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;We didn’t just give AI autonomy.&lt;br&gt;
We gave it authority—without accountability.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;That’s the gap.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;Have you seen weird or unexpected agent behavior in production? Drop your war stories below 👇&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;And if you’re building guardrails—what’s actually working?&lt;/em&gt;&lt;/p&gt;

</description>
      <category>ai</category>
      <category>security</category>
      <category>webdev</category>
      <category>devops</category>
    </item>
  </channel>
</rss>
