<?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: Rajesh Gunasekaran</title>
    <description>The latest articles on Forem by Rajesh Gunasekaran (@rgunasekaran).</description>
    <link>https://forem.com/rgunasekaran</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%2F2167227%2F4bc48c7a-09bb-4285-b3eb-6da95b4286e7.jpg</url>
      <title>Forem: Rajesh Gunasekaran</title>
      <link>https://forem.com/rgunasekaran</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/rgunasekaran"/>
    <language>en</language>
    <item>
      <title>Deploying Amazon MSK at Scale: A Platform Engineer's Journey at Wehkamp</title>
      <dc:creator>Rajesh Gunasekaran</dc:creator>
      <pubDate>Mon, 27 Oct 2025 14:14:43 +0000</pubDate>
      <link>https://forem.com/rgunasekaran/migrating-kakfa-to-amazon-msk-43bn</link>
      <guid>https://forem.com/rgunasekaran/migrating-kakfa-to-amazon-msk-43bn</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;At Wehkamp, we embarked on a journey to modernize our messaging infrastructure by migrating from self-managed Kafka on EC2 to Amazon MSK (Managed Streaming for Apache Kafka). This post shares real-world experiences from the platform team perspective - the challenges we faced, lessons learned, and how we built a scalable, multi-account MSK platform using Infrastructure as Code.&lt;/p&gt;

&lt;h2&gt;
  
  
  Background: Why MSK?
&lt;/h2&gt;

&lt;p&gt;Wehkamp's legacy Kafka infrastructure (established around 2014-2015) ran on EC2 instances. While it served us well initially, we faced several&lt;br&gt;
  challenges:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Scaling complexity: Manual broker management across multiple business units&lt;/li&gt;
&lt;li&gt;Operational overhead: Patching, ZooKeeper management, monitoring setup&lt;/li&gt;
&lt;li&gt;Stability concerns: Resource contention and performance issues&lt;/li&gt;
&lt;li&gt;Multi-account sprawl: Difficult to maintain consistency across environments&lt;/li&gt;
&lt;/ul&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%2F5zlssys7txvxaul6jsx4.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%2F5zlssys7txvxaul6jsx4.png" alt=" " width="800" height="429"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  Our Migration Goals
&lt;/h2&gt;

&lt;p&gt;We set out to achieve:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Reduce operational burden on the platform team&lt;/li&gt;
&lt;li&gt;Improve reliability with AWS-managed infrastructure&lt;/li&gt;
&lt;li&gt;Standardize Kafka deployments across all AWS accounts&lt;/li&gt;
&lt;li&gt;Enable faster scaling and easier maintenance&lt;/li&gt;
&lt;li&gt;Free up engineering time for higher-value work&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;
  
  
  Infrastructure as Code: Multi-Account MSK with Terraform
&lt;/h2&gt;

&lt;p&gt;At Wehkamp, we managed MSK clusters across multiple AWS accounts representing different business units and environments (dev, staging, production).&lt;/p&gt;

&lt;p&gt;Here's how we structured our Terraform setup:&lt;/p&gt;

&lt;p&gt;Repository Structure&lt;/p&gt;

&lt;p&gt;terraform/&lt;br&gt;
  ├── modules/&lt;br&gt;
  │   └── msk-cluster/&lt;br&gt;
  │       ├── main.tf&lt;br&gt;
  │       ├── variables.tf&lt;br&gt;
  │       ├── outputs.tf&lt;br&gt;
  │       └── broker-config.tf&lt;br&gt;
  ├── accounts/&lt;br&gt;
  │   ├── bu1-prod/&lt;br&gt;
  │   │   ├── main.tf&lt;br&gt;
  │   │   ├── variables.tf&lt;br&gt;
  │   │   └── msk.tf&lt;br&gt;
  │   ├── bu1-dev/&lt;br&gt;
  │   │   └── ...&lt;br&gt;
  │   ├── bu2-prod/&lt;br&gt;
  │   │   └── ...&lt;br&gt;
  │   └── bu2-dev/&lt;br&gt;
  │       └── ...&lt;br&gt;
  └── aws-config/&lt;br&gt;
      └── credentials&lt;/p&gt;
&lt;h2&gt;
  
  
  The MSK Module Pattern
&lt;/h2&gt;

&lt;p&gt;We created a reusable MSK module that handled all the complexity:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  # modules/msk-cluster/main.tf
  resource "aws_msk_cluster" "main" {
    cluster_name           = var.cluster_name
    kafka_version          = var.kafka_version
    number_of_broker_nodes = var.broker_count

    broker_node_group_info {
      instance_type   = var.instance_type
      client_subnets  = var.subnet_ids
      security_groups = [aws_security_group.msk.id]

      storage_info {
        ebs_storage_info {
          volume_size = var.storage_size_gb
        }
      }
    }

    configuration_info {
      arn      = aws_msk_configuration.main.arn
      revision = aws_msk_configuration.main.latest_revision
    }

    encryption_info {
      encryption_in_transit {
        client_broker = "TLS"
        in_cluster    = true
      }
    }

    tags = merge(var.common_tags, {
      Environment = var.environment
      ManagedBy   = "Terraform"
    })
  }
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Calling the Module Per Account
&lt;/h2&gt;

&lt;p&gt;Each AWS account directory called the module with environment-specific values:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  # accounts/bu1-prod/msk.tf
  module "msk_cluster" {
    source = "../../modules/msk-cluster"

    cluster_name    = "bu1-prod-msk"
    kafka_version   = "2.8.1"
    broker_count    = 3
    instance_type   = "kafka.m5.large"
    storage_size_gb = 1000
    subnet_ids      = data.aws_subnets.private.ids

    environment = "production"

    common_tags = {
      BusinessUnit = "BU1"
      CostCenter   = "engineering"
    }
  }
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Multi-Account Authentication
&lt;/h2&gt;

&lt;p&gt;Each AWS account directory contained its own variable files and configuration:&lt;/p&gt;

&lt;p&gt;terraform/&lt;br&gt;
  ├── accounts/&lt;br&gt;
  │   ├── bu1-prod/&lt;br&gt;
  │   │   ├── main.tf&lt;br&gt;
  │   │   ├── variables.tf&lt;br&gt;
  │   │   ├── terraform.tfvars  # Variables for this account&lt;br&gt;
  │   │   └── msk.tf&lt;br&gt;
  │   ├── bu1-dev/&lt;br&gt;
  │   │   ├── main.tf&lt;br&gt;
  │   │   ├── variables.tf&lt;br&gt;
  │   │   ├── terraform.tfvars  # Variables for this account&lt;br&gt;
  │   │   └── msk.tf&lt;/p&gt;

&lt;p&gt;We used AWS credential profiles with Terraform automatically picking up the tfvars file in each directory:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  # Deploying to specific account
  cd terraform/accounts/bu1-prod
  terraform init
  terraform plan
  terraform apply
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Terraform automatically used:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The terraform.tfvars file in the current directory&lt;/li&gt;
&lt;li&gt;The appropriate AWS credential profile configured in aws-config&lt;/li&gt;
&lt;li&gt;Module references pointing to ../../modules/msk-cluster&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  The Initial Setup
&lt;/h2&gt;

&lt;p&gt;When provisioning our MSK clusters, we followed &lt;a href="https://docs.aws.amazon.com/msk/latest/developerguide/bestpractices.html" rel="noopener noreferrer"&gt;https://docs.aws.amazon.com/msk/latest/developerguide/bestpractices.html&lt;/a&gt;. We calculated our&lt;br&gt;
  requirements based on:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Expected throughput (MB/s)&lt;/li&gt;
&lt;li&gt;Number of partitions&lt;/li&gt;
&lt;li&gt;Retention policies&lt;/li&gt;
&lt;li&gt;Client connections&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Based on these calculations, we initially deployed with kafka.m5.large instances.&lt;/p&gt;
&lt;h2&gt;
  
  
  Problem: Capacity Exceeded
&lt;/h2&gt;

&lt;p&gt;Shortly after production deployment, we hit a critical issue: our topic count exceeded what the instance type could accommodate. MSK has specific limits per broker instance type:&lt;/p&gt;

&lt;p&gt;| Instance Type    | Max Partitions per Broker |&lt;br&gt;
  |------------------|---------------------------|&lt;br&gt;
  | kafka.m5.large   | ~1000 partitions          |&lt;br&gt;
  | kafka.m5.xlarge  | ~2000 partitions          |&lt;br&gt;
  | kafka.m5.2xlarge | ~4000 partitions          |&lt;/p&gt;

&lt;p&gt;With multiple business units creating topics organically, we quickly exceeded capacity, causing:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Broker CPU spikes&lt;/li&gt;
&lt;li&gt;Increased replication lag&lt;/li&gt;
&lt;li&gt;Connection timeouts&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;
  
  
  Solution: Upgrade to kafka.m5.2xlarge
&lt;/h2&gt;

&lt;p&gt;We upgraded the instance type via Terraform:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  module "msk_cluster" {
    source = "../../modules/msk-cluster"

    # Changed from kafka.m5.large
    instance_type = "kafka.m5.2xlarge"

    # ... other config
  }


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;terraform apply&lt;br&gt;
  # MSK performs rolling upgrade, no downtime&lt;/p&gt;

&lt;p&gt;The upgrade worked smoothly - MSK performed a rolling update with zero downtime.&lt;/p&gt;

&lt;h2&gt;
  
  
  New Problem: Over-Provisioning &amp;amp; Cost
&lt;/h2&gt;

&lt;p&gt;A few weeks later, our AWS cost reports flagged a significant increase. We had over-provisioned:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Actual usage: ~1,500 partitions&lt;/li&gt;
&lt;li&gt;Provisioned capacity: kafka.m5.2xlarge (4,000 partitions)&lt;/li&gt;
&lt;li&gt;Cost impact: 2x more expensive than needed&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;We wanted to downgrade to kafka.m5.xlarge (the Goldilocks size), but discovered a critical MSK limitation:&lt;/p&gt;

&lt;p&gt;⚠️ MSK does NOT support downgrading instance types through the console or API.&lt;/p&gt;

&lt;p&gt;You can only upgrade, never downgrade.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Workaround: AWS Support Case
&lt;/h2&gt;

&lt;p&gt;We raised an AWS Support case requesting manual downgrade assistance. Here's what we learned:&lt;/p&gt;

&lt;p&gt;AWS Support Options:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Recommended approach: Create new cluster with correct size, migrate topics

&lt;ul&gt;
&lt;li&gt;Pros: Clean slate, proper sizing&lt;/li&gt;
&lt;li&gt;Cons: Complex migration, client reconfiguration&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Manual intervention (what we did): AWS engineers performed backend downgrade

&lt;ul&gt;
&lt;li&gt;Pros: Faster, no client changes&lt;/li&gt;
&lt;li&gt;Cons: Requires support case, not guaranteed for all scenarios&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The AWS support team successfully downgraded our cluster, but the process took 48-72 hours and required careful planning during a maintenance window.&lt;/p&gt;

&lt;h2&gt;
  
  
  Lessons Learned
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;Start conservatively, but not too conservatively

&lt;ul&gt;
&lt;li&gt;Use monitoring data to right-size within first 30 days&lt;/li&gt;
&lt;li&gt;Build in 30-40% headroom for growth&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Monitor partition count actively

&lt;ul&gt;
&lt;li&gt;Set CloudWatch alarms for partition count thresholds&lt;/li&gt;
&lt;li&gt;Implement topic creation governance (approval process)&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;MSK instance type changes are one-way

&lt;ul&gt;
&lt;li&gt;You can upgrade easily, but downgrades require AWS support&lt;/li&gt;
&lt;li&gt;Plan sizing carefully to avoid cost optimization headaches&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Consider kafka.m5.xlarge as default starting point

&lt;ul&gt;
&lt;li&gt;Good balance of capacity and cost&lt;/li&gt;
&lt;li&gt;Enough headroom for most workloads&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Implement topic quotas

&lt;ul&gt;
&lt;li&gt;Prevent unbounded topic/partition growth&lt;/li&gt;
&lt;li&gt;Use Kafka quotas or approval workflows&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Cost Optimization
&lt;/h2&gt;

&lt;p&gt;After this experience, we implemented partition count monitoring:&lt;/p&gt;

&lt;p&gt;# CloudWatch alarm for partition count&lt;br&gt;
  resource "aws_cloudwatch_metric_alarm" "partition_count" {&lt;br&gt;
    alarm_name          = "msk-partition-count-high"&lt;br&gt;
    comparison_operator = "GreaterThanThreshold"&lt;br&gt;
    evaluation_periods  = 2&lt;br&gt;
    metric_name         = "PartitionCount"&lt;br&gt;
    namespace           = "AWS/Kafka"&lt;br&gt;
    period              = 300&lt;br&gt;
    statistic           = "Average"&lt;br&gt;
    threshold           = 1500  # 75% of kafka.m5.xlarge capacity&lt;br&gt;
    alarm_description   = "MSK partition count approaching instance type limit"&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;dimensions = {
  "Cluster Name" = aws_msk_cluster.main.cluster_name
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;}&lt;/p&gt;

&lt;p&gt;Estimated cost savings: ~$500/month per cluster by right-sizing.&lt;/p&gt;




&lt;p&gt;Operational Challenge #2: Production Incident - MSK Disk Space Crisis&lt;/p&gt;

&lt;h2&gt;
  
  
  Our Monitoring Setup
&lt;/h2&gt;

&lt;p&gt;At Wehkamp, we implemented a tiered alerting strategy:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Informational alerts → Slack channel #aws-platform-alerts&lt;/li&gt;
&lt;li&gt;Critical alerts → Immediate action required&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The Incident Timeline&lt;/p&gt;

</description>
      <category>architecture</category>
      <category>aws</category>
      <category>devops</category>
    </item>
    <item>
      <title>Upgrading EKS from v1.31 to v1.32</title>
      <dc:creator>Rajesh Gunasekaran</dc:creator>
      <pubDate>Tue, 30 Sep 2025 03:46:34 +0000</pubDate>
      <link>https://forem.com/rgunasekaran/upgrading-eks-from-v131-to-v132-dmf</link>
      <guid>https://forem.com/rgunasekaran/upgrading-eks-from-v131-to-v132-dmf</guid>
      <description></description>
      <category>aws</category>
      <category>kubernetes</category>
      <category>tutorial</category>
      <category>devops</category>
    </item>
    <item>
      <title>Production Ready Serverless</title>
      <dc:creator>Rajesh Gunasekaran</dc:creator>
      <pubDate>Sun, 31 Aug 2025 17:26:48 +0000</pubDate>
      <link>https://forem.com/rgunasekaran/production-ready-serverless-576</link>
      <guid>https://forem.com/rgunasekaran/production-ready-serverless-576</guid>
      <description></description>
      <category>serverless</category>
      <category>production</category>
      <category>cloud</category>
      <category>deployment</category>
    </item>
    <item>
      <title>Deploying a Sample Retail Store App on Amazon EKS – Step-by-Step Guide</title>
      <dc:creator>Rajesh Gunasekaran</dc:creator>
      <pubDate>Wed, 30 Jul 2025 20:56:17 +0000</pubDate>
      <link>https://forem.com/rgunasekaran/deploying-a-sample-retail-store-app-on-amazon-eks-step-by-step-guide-484p</link>
      <guid>https://forem.com/rgunasekaran/deploying-a-sample-retail-store-app-on-amazon-eks-step-by-step-guide-484p</guid>
      <description>&lt;h2&gt;
  
  
  Overview
&lt;/h2&gt;

&lt;p&gt;In this workshop, we will walk through deploying a sample retail store application on Amazon EKS (Elastic Kubernetes Service) using a combination of CloudFormation and Terraform. This guide is divided into logical stages, from setting up foundational infrastructure to running your app on Spot and Graviton instances.&lt;/p&gt;

&lt;h2&gt;
  
  
  Step 1: Set Up AWS Infrastructure with CloudFormation
&lt;/h2&gt;

&lt;p&gt;We’ll start by using AWS CloudFormation to provision the foundational network infrastructure (VPC, subnets, Internet Gateway, etc.) that EKS requires.&lt;/p&gt;

&lt;h2&gt;
  
  
  What to do:
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Create a CloudFormation stack using a predefined template (YAML/JSON)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Include resources:&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;VPC&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Public and Private Subnets&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;NAT Gateways&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Route Tables&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;Launching the CloudFormation stack using a predefined template to set up a code-server IDE for the EKS workshop.&lt;/em&gt;&lt;br&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%2Fwytv7iqsa6dp39epupmq.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%2Fwytv7iqsa6dp39epupmq.png" alt="Create a Cloudformation stack named eks-workshop-ide" width="800" height="310"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Reviewing permissions and acknowledging IAM capabilities before creating the eks-workshop-ide CloudFormation stack.&lt;/em&gt;&lt;br&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%2Fyufqikb0mfkspzj9poq2.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%2Fyufqikb0mfkspzj9poq2.png" alt=" " width="800" height="360"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;CloudFormation stack eks-workshop-ide created successfully with status CREATE_COMPLETE.&lt;/em&gt;&lt;br&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%2F2on9t4tky5jq9xw1dr3m.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%2F2on9t4tky5jq9xw1dr3m.png" alt=" " width="800" height="207"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;The CloudFormation stack will take roughly 5 minutes to deploy, and once completed you can retrieve information required to continue from the Outputs tab:&lt;/em&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%2Fecmh415zie6nu5wso9nq.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%2Fecmh415zie6nu5wso9nq.png" alt=" " width="800" height="361"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The IdeUrl output contains the URL to enter in your browser to access the IDE. The IdePasswordSecret contains a link to an AWS Secrets Manger secret that contains a generated password for the IDE.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;To retrieve the password open that URL and click the Retrieve button, the password will then be available for you to copy::&lt;/em&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%2Fl2s2f24ku6q7cjmant06.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%2Fl2s2f24ku6q7cjmant06.png" alt=" " width="800" height="173"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Open the IDE URL provided and you will be prompted for the password:&lt;/em&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%2Fnvz0xajrx75v2crdivf0.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%2Fnvz0xajrx75v2crdivf0.png" alt=" " width="800" height="328"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;After submitting your password you will be presented with the initial VSCode screen&lt;/em&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%2Faokbhlpp129hegaay8pa.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%2Faokbhlpp129hegaay8pa.png" alt=" " width="800" height="263"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  Step 2: Prepare Terraform Configuration
&lt;/h2&gt;

&lt;p&gt;With the CloudFormation networking layer in place, it’s time to define the rest of our infrastructure using Terraform. This is where we set up the EKS cluster, node groups, and other supporting components.&lt;/p&gt;

&lt;p&gt;For the given configuration, Terraform will create the workshop environment with the following:&lt;/p&gt;
&lt;h2&gt;
  
  
  Resources created by Terraform:
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;A VPC across three Availability Zones&lt;/li&gt;
&lt;li&gt;An Amazon EKS Cluster&lt;/li&gt;
&lt;li&gt;An IAM OIDC Provider for enabling IAM roles for service accounts&lt;/li&gt;
&lt;li&gt;A Managed Node Group named default for general workloads&lt;/li&gt;
&lt;li&gt;Configuration of the Amazon VPC CNI plugin to use prefix delegation (for improved IP management and scaling)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;Terraform initial setup, including downloading necessary Terraform configuration files for the EKS workshop.&lt;/em&gt;&lt;br&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%2Fra27qp6xbou67tal65gj.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%2Fra27qp6xbou67tal65gj.png" alt=" " width="800" height="213"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Terraform init in action&lt;/em&gt;&lt;br&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%2F27yaofr0nj4ceim4vcgd.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%2F27yaofr0nj4ceim4vcgd.png" alt=" " width="800" height="146"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Terraform successfully deploys the EKS cluster&lt;/em&gt;&lt;br&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%2Fza6wiusye8odqm7wok1f.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%2Fza6wiusye8odqm7wok1f.png" alt=" " width="800" height="376"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;EKS cluster Up &amp;amp; running in AWS console&lt;/em&gt;&lt;br&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%2Fgpsncwqxcgvxrj44zx9m.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%2Fgpsncwqxcgvxrj44zx9m.png" alt=" " width="800" height="328"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Node Group config within EKS cluster&lt;/em&gt;&lt;br&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%2F1h8b3xgga552f0cqko7b.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%2F1h8b3xgga552f0cqko7b.png" alt=" " width="800" height="368"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  Step 3: Set Up/Prepare the EKS Cluster environment
&lt;/h2&gt;

&lt;p&gt;&lt;em&gt;Initializing the EKS workshop environment&lt;/em&gt;&lt;br&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%2Fusyhvufexobrlivgh8zg.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%2Fusyhvufexobrlivgh8zg.png" alt=" " width="800" height="297"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Verify the EKS cluster nodes, namespaces using kubectl command&lt;/em&gt;&lt;br&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%2Fe8lvca0e1qmg5jsmiurg.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%2Fe8lvca0e1qmg5jsmiurg.png" alt=" " width="800" height="167"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  Step 4: Deploy the Sample Retail Store App
&lt;/h2&gt;

&lt;p&gt;In this workshop, we'll deploy the sample retail application efficiently using the power of Kustomize. The following kustomization file shows how you can reference other kustomizations and deploy multiple components together:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
  - rabbitmq
  - catalog
  - carts
  - checkout
  - assets
  - orders
  - ui
  - other
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
    </item>
    <item>
      <title>What is Infrastructure as Code (IaC) and What are the benefits of using it ?</title>
      <dc:creator>Rajesh Gunasekaran</dc:creator>
      <pubDate>Sat, 19 Jul 2025 09:48:27 +0000</pubDate>
      <link>https://forem.com/rgunasekaran/what-is-infrastructure-as-code-iac-and-what-are-the-benefits-of-using-it--38gk</link>
      <guid>https://forem.com/rgunasekaran/what-is-infrastructure-as-code-iac-and-what-are-the-benefits-of-using-it--38gk</guid>
      <description>&lt;h2&gt;
  
  
  What is Infrastructure as Code (IaC) ?
&lt;/h2&gt;

&lt;p&gt;Infrastructure as Code (IaC) is a declarative approach to provisioning and managing infrastructure using tools such as Terraform, CloudFormation, Ansible, and others.&lt;/p&gt;

&lt;p&gt;With IaC, there’s no need to manually log in to cloud provider consoles like AWS, Azure, or GCP to create infrastructure resources.&lt;/p&gt;

&lt;p&gt;The core idea of IaC is that you define your infrastructure in code—allowing you to create, update, and destroy resources programmatically.&lt;/p&gt;

&lt;p&gt;By using IaC across both on-premises and cloud environments, organizations can deliver dynamic, scalable infrastructure to internal teams and ensure a seamless experience for customers.&lt;/p&gt;

&lt;p&gt;IaC has become a foundational practice in DevOps and cloud-native engineering, empowering teams to build scalable, consistent, and reproducible environments with confidence.&lt;/p&gt;

&lt;h2&gt;
  
  
  Benefits of IaC:
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Consistency: Prevent configuration drift by ensuring the same code provisions the same infrastructure every time.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Version Control: Use Git to track changes, collaborate across teams, and roll back when needed.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Automation: Integrate with CI/CD pipelines to automatically deploy infrastructure without manual intervention.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Speed: Launch and update environments faster and more reliably than through manual processes.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Reuse: Encapsulate infrastructure into reusable modules, enabling teams to build on top of proven, well-documented components.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Documentation: With Terraform and other IaC tools, infrastructure definitions live in code repositories—making them easy to read, manage, and understand.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Iac Tools:
&lt;/h2&gt;

&lt;p&gt;Below are some of the most widely adopted Infrastructure as Code tools used globally. These tools help automate infrastructure deployment on both private and public cloud platforms:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Hashicorp Terraform - terraform.io&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;AWS Cloud Formation - aws.amazon.com/cloudformation&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Azure Resource Manager (ARM) - azure.microsoft.com&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Google Cloud Deployment Manager - cloud.google.com/deployment-manager/docs&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Pulumi - pulumi.com&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Conclusion:
&lt;/h2&gt;

&lt;p&gt;I hope this gave you a clear understanding of what Infrastructure as Code (IaC) is and the key benefits it brings. Whether you’re managing on-premises systems or cloud environments, IaC provides a reliable, scalable, and efficient way to provision and maintain infrastructure. Embracing IaC is a strong step toward automation, collaboration, and modern DevOps practices.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Securing Terraform Automation: Atlantis IAM Design and Implementation in AWS</title>
      <dc:creator>Rajesh Gunasekaran</dc:creator>
      <pubDate>Mon, 30 Jun 2025 10:03:57 +0000</pubDate>
      <link>https://forem.com/rgunasekaran/securing-terraform-automation-atlantis-iam-design-and-implementation-in-aws-3jg9</link>
      <guid>https://forem.com/rgunasekaran/securing-terraform-automation-atlantis-iam-design-and-implementation-in-aws-3jg9</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;Infrastructure as Code (IaC) tools like Terraform enable organizations to manage cloud resources efficiently. However, managing permissions for Terraform operations is crucial to maintaining security and compliance. This article explores how to design and implement IAM roles and policies for Atlantis in an Amazon EKS environment.&lt;/p&gt;

&lt;h2&gt;
  
  
  Background
&lt;/h2&gt;

&lt;p&gt;Atlantis is an open-source tool that automates Terraform workflows. It allows teams to collaborate on infrastructure changes via pull requests (PRs). Since Atlantis executes Terraform commands on behalf of users, it requires appropriate AWS IAM permissions to perform its tasks securely.&lt;/p&gt;

&lt;h2&gt;
  
  
  Challenges in IAM Design for Atlantis
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;Principle of Least Privilege (PoLP): Atlantis should have only the minimum permissions necessary to apply infrastructure changes.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Managing Multi-Account Access: Organizations often deploy infrastructure across multiple AWS accounts, requiring cross-account access management.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Securely Storing AWS Credentials: Storing and managing AWS credentials securely is essential to prevent unauthorized access.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Audit and Compliance: Tracking who initiated infrastructure changes and ensuring compliance with security policies is a key challenge. &lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Solution Approach
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Using IAM Roles Instead of Static Credentials
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Instead of using AWS access keys, Atlantis should assume an IAM role with specific permissions.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Setting Up IAM Roles for Atlantis
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Create an IAM Role for Atlantis: Define an IAM role with trust policies allowing Atlantis (running in Amazon EKS) to assume it.&lt;/li&gt;
&lt;li&gt;Attach Least Privilege Policies: Assign policies granting only the necessary permissions for Terraform actions.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Enabling Cross-Account Access
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Create IAM roles in each AWS account that Atlantis needs to manage.&lt;/li&gt;
&lt;li&gt;Update trust policies to allow Atlantis to assume these roles.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Storing and Using IAM Credentials Securely
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Use Kubernetes Service Account IAM Roles (IRSA) to provide Atlantis with temporary credentials.&lt;/li&gt;
&lt;li&gt;Avoid storing long-term AWS credentials in configuration files.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Implementing Logging and Auditing
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Enable AWS CloudTrail to track Atlantis’s API calls.&lt;/li&gt;
&lt;li&gt;Use AWS IAM Access Analyzer to review granted permissions.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Step-by-Step Implementation
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Step 1: Create an IAM Role for Atlantis
&lt;/h3&gt;

&lt;p&gt;&lt;code&gt;aws iam create-role --role-name AtlantisRole --assume-role-policy-document file://trust-policy.json&lt;/code&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The trust policy (trust-policy.json) should allow EKS to assume the role.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Step 2: Attach Required IAM Policies
&lt;/h3&gt;

&lt;p&gt;Attach policies that grant only necessary permissions.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;aws iam attach-role-policy --role-name AtlantisRole --policy-arn arn:aws:iam::aws:policy/TerraformApplyPolicy&lt;/code&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 3: Enable IRSA for Atlantis in EKS
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Create a Kubernetes service account with IAM role annotations.&lt;/li&gt;
&lt;li&gt;Update the Atlantis deployment to use the service account.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Step 4: Configure Cross-Account Role Assumption
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Create a role in each target AWS account.&lt;/li&gt;
&lt;li&gt;Update the trust policy to allow AtlantisRole to assume it.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Step 5: Verify and Monitor Access
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Test Atlantis’s ability to assume roles and apply Terraform changes.&lt;/li&gt;
&lt;li&gt;Monitor API calls using AWS CloudTrail and IAM Access Analyzer.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;By designing a secure IAM strategy for Atlantis, organizations can ensure Terraform automation runs safely while adhering to security best practices. This structured approach balances security with operational efficiency, enabling teams to manage infrastructure confidently.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Step-by-Step Process of Atlantis Executing Terraform</title>
      <dc:creator>Rajesh Gunasekaran</dc:creator>
      <pubDate>Sat, 11 Jan 2025 07:11:39 +0000</pubDate>
      <link>https://forem.com/rgunasekaran/streamlining-terraform-workflows-with-atlantis-on-amazon-eks-227o</link>
      <guid>https://forem.com/rgunasekaran/streamlining-terraform-workflows-with-atlantis-on-amazon-eks-227o</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;Atlantis is an essential tool for automating Terraform workflows. It provides a GitOps-style approach where Terraform plans and applies are triggered by pull requests (PRs). This step-by-step guide details how Atlantis processes Terraform changes when a developer submits a PR.&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%2Fscmrlok3rc3svgahznn7.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%2Fscmrlok3rc3svgahznn7.png" alt="Atlantis automating Terraform workflows on Amazon EKS" width="800" height="329"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Prerequisites
&lt;/h2&gt;

&lt;p&gt;Before implementing Atlantis, ensure you have the following:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;An Amazon EKS cluster with Atlantis deployed&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;A properly configured GitHub repository&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;AWS IAM roles and permissions set up for Terraform execution&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Backend configuration for storing Terraform state (e.g., AWS S3 and DynamoDB)&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Step 1: Developer Submits a PR with Terraform Changes
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;A developer modifies Terraform configuration files and pushes the changes to a feature branch.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;A pull request (PR) is created against the main branch in the GitHub repository.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Atlantis automatically detects the PR and adds a comment indicating that a Terraform plan is in progress.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Step 2: Atlantis Runs terraform plan
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Atlantis checks out the PR branch inside the EKS pod.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;It executes terraform init to initialize the working directory.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;It runs terraform plan to generate an execution plan.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Atlantis posts the output of terraform plan as a comment in the PR.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Developers review the plan and validate the proposed infrastructure changes.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Step 3: Reviewer Approves the Plan
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;If the plan looks good, an authorized reviewer (or the developer themselves) comments atlantis apply on the PR.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Atlantis detects the command and proceeds with applying the changes.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Step 4: Atlantis Runs terraform apply
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Atlantis reinitializes the working directory and ensures the state is up-to-date.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;It executes terraform apply to make the infrastructure changes.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Once completed, Atlantis updates the PR with the results of the apply command.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;If successful, the infrastructure is updated, and Terraform state is stored in the configured backend.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Step 5: Merging the PR
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;After a successful apply, the PR is ready to be merged into the main branch.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;The developer or reviewer merges the PR.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Atlantis automatically removes the workspace and cleans up temporary files related to the PR.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Step 6: Continuous Monitoring and Improvements
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Regularly update Atlantis configurations and Terraform modules.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Implement policies and checks to ensure compliance.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Use Atlantis logging and monitoring to troubleshoot any issues.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;By following this structured approach, teams can streamline their Terraform workflows, enhance collaboration, and maintain infrastructure as code best practices using Atlantis on Amazon EKS.&lt;/p&gt;

</description>
      <category>aws</category>
      <category>awscommunity</category>
      <category>awscommunitybuilder</category>
    </item>
  </channel>
</rss>
