<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Terraform on Dev &amp; Platform Engineering Hub</title><link>https://rhidayat.work/topics/terraform/</link><description>Recent content in Terraform on Dev &amp; Platform Engineering Hub</description><generator>Hugo -- gohugo.io</generator><language>en</language><copyright>© 2026 Rachmat Hidayat</copyright><lastBuildDate>Sun, 09 Aug 2026 11:40:00 +0000</lastBuildDate><atom:link href="https://rhidayat.work/topics/terraform/index.xml" rel="self" type="application/rss+xml"/><item><title>Terraform Ep 15: Infrastructure Unit Testing with Terratest (Golang)</title><link>https://rhidayat.work/series/terraform/advanced/15-testing-with-terratest/</link><pubDate>Sun, 09 Aug 2026 11:40:00 +0000</pubDate><guid>https://rhidayat.work/series/terraform/advanced/15-testing-with-terratest/</guid><description>Running &amp;rsquo;terraform plan&amp;rsquo; is not enough to guarantee your infrastructure works. In this final episode, we bridge the gap between DevOps and Software Engineering by writing automated Golang tests using Terratest. We will programmatically provision infrastructure, assert its correctness, and tear it down.</description></item><item><title>Terraform Ep 14: Achieving DRY Architecture with Terragrunt</title><link>https://rhidayat.work/series/terraform/advanced/14-terragrunt-and-dry-architecture/</link><pubDate>Sun, 09 Aug 2026 11:30:00 +0000</pubDate><guid>https://rhidayat.work/series/terraform/advanced/14-terragrunt-and-dry-architecture/</guid><description>As your Terraform codebase scales across dozens of microservices and environments, you will find yourself copy-pasting the same &amp;lsquo;backend&amp;rsquo; and &amp;lsquo;provider&amp;rsquo; blocks repeatedly. Terragrunt is a powerful wrapper that eliminates this repetition, allowing you to define global configurations once.</description></item><item><title>Terraform Ep 13: Advanced State Manipulation (Surgical Refactoring)</title><link>https://rhidayat.work/series/terraform/advanced/13-advanced-state-manipulation/</link><pubDate>Sun, 09 Aug 2026 11:20:00 +0000</pubDate><guid>https://rhidayat.work/series/terraform/advanced/13-advanced-state-manipulation/</guid><description>Refactoring HCL code is dangerous. If you rename a resource block, Terraform will attempt to destroy the old resource and recreate it. In this episode, we learn how to use &amp;lsquo;moved&amp;rsquo; blocks and the state CLI to refactor code safely, preventing catastrophic database deletions.</description></item><item><title>Terraform Ep 12: CI/CD Automation with Terraform Cloud and GitHub Actions</title><link>https://rhidayat.work/series/terraform/advanced/12-cicd-with-terraform-cloud/</link><pubDate>Sun, 09 Aug 2026 11:10:00 +0000</pubDate><guid>https://rhidayat.work/series/terraform/advanced/12-cicd-with-terraform-cloud/</guid><description>Running &amp;rsquo;terraform apply&amp;rsquo; from a local laptop is a major security and compliance risk. In this episode, we transition to a GitOps workflow. You will learn how to automate Terraform plans on Pull Requests, and automatically apply changes upon merging to the main branch using GitHub Actions.</description></item><item><title>Terraform Ep 11: Managing Multi-Environment Architecture (Workspaces vs Directories)</title><link>https://rhidayat.work/series/terraform/advanced/11-workspaces-and-environments/</link><pubDate>Sun, 09 Aug 2026 11:00:00 +0000</pubDate><guid>https://rhidayat.work/series/terraform/advanced/11-workspaces-and-environments/</guid><description>Welcome to Tier 3: Advanced Platform Engineering. You now know how to write reusable modules and store state remotely. But how do you safely deploy identical infrastructure to both Staging and Production without them colliding? We explore Workspaces and Directory Isolation.</description></item><item><title>Terraform Ep 10: Remote State Backends and Concurrency Locking</title><link>https://rhidayat.work/series/terraform/intermediate/10-remote-state-and-locking/</link><pubDate>Sun, 09 Aug 2026 10:40:00 +0000</pubDate><guid>https://rhidayat.work/series/terraform/intermediate/10-remote-state-and-locking/</guid><description>Local state files are fine for solo learning, but catastrophic for team environments. In this episode, we will solve the &amp;lsquo;state file drift&amp;rsquo; problem by configuring a Remote Backend on AWS S3, and preventing simultaneous executions using DynamoDB locking.</description></item><item><title>Terraform Ep 9: Architecting Reusable, Production-Grade Modules</title><link>https://rhidayat.work/series/terraform/intermediate/09-writing-reusable-modules/</link><pubDate>Sun, 09 Aug 2026 10:30:00 +0000</pubDate><guid>https://rhidayat.work/series/terraform/intermediate/09-writing-reusable-modules/</guid><description>Modules are the functions of the Terraform ecosystem. In this episode, we will build a reusable AWS VPC module from scratch, define explicit inputs and outputs, and consume it from a separate Root Module. Stop copy-pasting code and start building a self-service infrastructure catalog.</description></item><item><title>Terraform Ep 8: Generating Nested Configurations with Dynamic Blocks</title><link>https://rhidayat.work/series/terraform/intermediate/08-dynamic-blocks/</link><pubDate>Sun, 09 Aug 2026 10:20:00 +0000</pubDate><guid>https://rhidayat.work/series/terraform/intermediate/08-dynamic-blocks/</guid><description>While &amp;lsquo;count&amp;rsquo; and &amp;lsquo;for_each&amp;rsquo; duplicate entire resources, &amp;lsquo;dynamic&amp;rsquo; blocks duplicate nested configurations &lt;em&gt;inside&lt;/em&gt; a single resource. Discover how to build highly flexible, list-driven Security Groups and Route Tables without repeating HCL blocks.</description></item><item><title>Terraform Ep 7: Advanced Looping Strategies (count vs for_each)</title><link>https://rhidayat.work/series/terraform/intermediate/07-loops-with-count-and-for-each/</link><pubDate>Sun, 09 Aug 2026 10:10:00 +0000</pubDate><guid>https://rhidayat.work/series/terraform/intermediate/07-loops-with-count-and-for-each/</guid><description>Copy-pasting resource blocks is a cardinal sin in Platform Engineering. In this episode, we will deploy identical infrastructure fleets using loops. You will learn the critical differences between &amp;lsquo;count&amp;rsquo; and &amp;lsquo;for_each&amp;rsquo;, and why &amp;lsquo;count&amp;rsquo; can accidentally destroy your production servers if used incorrectly.</description></item><item><title>Terraform Ep 6: Local Values, Built-in Functions, and Interpolation</title><link>https://rhidayat.work/series/terraform/intermediate/06-local-values-and-functions/</link><pubDate>Sun, 09 Aug 2026 10:00:00 +0000</pubDate><guid>https://rhidayat.work/series/terraform/intermediate/06-local-values-and-functions/</guid><description>Terraform is not just static configuration; it is a powerful programming language. In this episode, we explore how to perform string interpolations, use mathematical functions, and centralize complex expressions using the &amp;rsquo;locals&amp;rsquo; block to keep your code DRY.</description></item><item><title>Terraform Ep 5: Querying Existing Cloud Infrastructure with Data Sources</title><link>https://rhidayat.work/series/terraform/fundamental/05-data-sources/</link><pubDate>Sun, 09 Aug 2026 09:50:00 +0000</pubDate><guid>https://rhidayat.work/series/terraform/fundamental/05-data-sources/</guid><description>Not everything in your cloud is managed by Terraform. In this episode, you will learn how to use the &amp;lsquo;data&amp;rsquo; block to interrogate the AWS API. Fetch the latest Ubuntu AMI ID dynamically, or retrieve a VPC ID created by the Networking team, ensuring your code remains hardcode-free.</description></item><item><title>Terraform Ep 4: Input Variables, Outputs, and Data Types</title><link>https://rhidayat.work/series/terraform/fundamental/04-input-variables-and-outputs/</link><pubDate>Sun, 09 Aug 2026 09:40:00 +0000</pubDate><guid>https://rhidayat.work/series/terraform/fundamental/04-input-variables-and-outputs/</guid><description>Hardcoding values in Terraform is a bad practice. In this episode, we will introduce Input Variables and Data Types to make your code reusable across multiple environments. You will also learn how to extract critical information using Outputs.</description></item><item><title>Terraform Ep 3: Declaring Resources and Dependency Management</title><link>https://rhidayat.work/series/terraform/fundamental/03-declaring-resources/</link><pubDate>Sun, 09 Aug 2026 09:30:00 +0000</pubDate><guid>https://rhidayat.work/series/terraform/fundamental/03-declaring-resources/</guid><description>It is time to build real infrastructure. In this episode, we will declare an AWS Virtual Private Cloud (VPC) and a Subnet. You will learn how Terraform intelligently determines the correct order of creation using the Dependency Graph, preventing race conditions.</description></item><item><title>Terraform Ep 2: Providers, Plugins, and Secure Authentication</title><link>https://rhidayat.work/series/terraform/fundamental/02-providers-and-authentication/</link><pubDate>Sun, 09 Aug 2026 09:20:00 +0000</pubDate><guid>https://rhidayat.work/series/terraform/fundamental/02-providers-and-authentication/</guid><description>Terraform itself cannot create an AWS EC2 instance. It relies on &amp;lsquo;Providers&amp;rsquo; (plugins) to translate HCL code into cloud-specific API calls. In this episode, we connect Terraform to AWS and establish a secure, production-grade authentication mechanism.</description></item><item><title>Terraform Ep 1: Introduction to IaC and the State File</title><link>https://rhidayat.work/series/terraform/fundamental/01-introduction-and-state/</link><pubDate>Sun, 09 Aug 2026 09:10:00 +0000</pubDate><guid>https://rhidayat.work/series/terraform/fundamental/01-introduction-and-state/</guid><description>Stop deploying cloud resources manually. In this first episode, we will transform your approach to cloud architecture by introducing declarative IaC. You will learn how Terraform tracks physical resources using the state file, and execute your first local configuration.</description></item></channel></rss>