<?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: Winnie Wambui</title>
    <description>The latest articles on Forem by Winnie Wambui (@winnie_wambui).</description>
    <link>https://forem.com/winnie_wambui</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%2F3831032%2F1a228ef5-bac3-48a8-9490-6fc4bf1e9560.png</url>
      <title>Forem: Winnie Wambui</title>
      <link>https://forem.com/winnie_wambui</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/winnie_wambui"/>
    <language>en</language>
    <item>
      <title>Step-by-Step Guide to Setting Up Terraform, AWS CLI, and Your AWS Environment</title>
      <dc:creator>Winnie Wambui</dc:creator>
      <pubDate>Wed, 18 Mar 2026 17:56:18 +0000</pubDate>
      <link>https://forem.com/winnie_wambui/step-by-step-guide-to-setting-up-terraform-aws-cli-and-your-aws-environment-2f6n</link>
      <guid>https://forem.com/winnie_wambui/step-by-step-guide-to-setting-up-terraform-aws-cli-and-your-aws-environment-2f6n</guid>
      <description>&lt;h2&gt;
  
  
  &lt;strong&gt;Introduction&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Setting up your environment correctly is the foundation of working with Terraform. In this guide, I’ll walk through how I installed Terraform, configured the AWS CLI, and connected everything to AWS.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;1. Setting Up AWS&lt;/strong&gt;
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Created an AWS account
&lt;/li&gt;
&lt;li&gt;Enabled MFA for security
&lt;/li&gt;
&lt;li&gt;Created an IAM user with programmatic access
&lt;/li&gt;
&lt;li&gt;Attached necessary permissions
&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;2. Installing AWS CLI&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Installed AWS CLI and configured it:&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%2Fkt0fj8igoth4mtt92gen.jpeg" 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%2Fkt0fj8igoth4mtt92gen.jpeg" alt="AWS CLI Setup" width="800" height="127"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;3. Installing Terraform&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Downloaded and installed Terraform, then verified:&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%2F3ntsa9v9ni89acjz1i0h.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%2F3ntsa9v9ni89acjz1i0h.png" alt="Terraform Version" width="478" height="118"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;4. Connecting Terraform to AWS&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Terraform automatically uses AWS CLI credentials.&lt;/p&gt;

&lt;p&gt;Tested connection using:&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%2F85tg87jy5uaogy5owm7o.jpeg" 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%2F85tg87jy5uaogy5owm7o.jpeg" alt="AWS Identity" width="780" height="205"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;VSCode Extensions&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;I installed the following extensions in Visual Studio Code:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;HashiCorp Terraform&lt;/li&gt;
&lt;li&gt;AWS Toolkit&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;SETUP CHALLENGES&lt;br&gt;
&lt;strong&gt;1.Confusion Between Root User and IAM User&lt;/strong&gt;*&lt;br&gt;
Initially, I was unsure whether to use root credentials or create a new user.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Solution:&lt;/strong&gt;&lt;br&gt;
I learned that it is best practice to create an IAM user with programmatic access instead of using the root account. I created a dedicated user and generated Access Key ID and Secret Access Key.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2.AWS CLI Configuration Errors&lt;/strong&gt;&lt;br&gt;
After running aws configure, some commands failed due to incorrect credentials.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Solution:&lt;/strong&gt;&lt;br&gt;
I rechecked my credentials and region, then reconfigured using aws configure.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;CHAPTER TWO LEARNINGS&lt;/strong&gt;&lt;br&gt;
From Chapter 2, I learned how Terraform authenticates with AWS.&lt;br&gt;
Terraform does not store credentials directly. Instead, it relies on credentials configured through the AWS CLI using the aws configure command. These credentials are stored locally and used whenever Terraform interacts with AWS services.&lt;/p&gt;

&lt;p&gt;Terraform 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;li&gt;Default region
to authenticate and provision infrastructure on AWS.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;What Happens If You Use Root Credentials?&lt;/strong&gt;&lt;br&gt;
Using root credentials is strongly discouraged because:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The root account has full administrative access&lt;/li&gt;
&lt;li&gt;Any mistake could lead to serious security risks or unexpected charges&lt;/li&gt;
&lt;li&gt;It violates security best practices&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Using an IAM user is safer because:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;It follows the principle of least privilege&lt;/li&gt;
&lt;li&gt;Permissions can be controlled and limited&lt;/li&gt;
&lt;li&gt;It reduces risk in case credentials are exposed&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Conclusion&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;By completing this setup, I now have a fully working environment ready to deploy infrastructure using Terraform.&lt;/p&gt;

</description>
      <category>aws</category>
      <category>beginners</category>
      <category>terraform</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>What is Infrastructure as Code and Why It’s Transforming DevOps</title>
      <dc:creator>Winnie Wambui</dc:creator>
      <pubDate>Wed, 18 Mar 2026 12:22:04 +0000</pubDate>
      <link>https://forem.com/winnie_wambui/what-is-infrastructure-as-code-and-why-its-transforming-devops-3al6</link>
      <guid>https://forem.com/winnie_wambui/what-is-infrastructure-as-code-and-why-its-transforming-devops-3al6</guid>
      <description>&lt;p&gt;&lt;strong&gt;Introduction&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;In today’s fast-paced tech world, building software is no longer just about writing code—it’s about delivering it reliably, consistently, and at scale. This is where Infrastructure as Code (IaC) comes in.&lt;/p&gt;

&lt;p&gt;IaC is one of the core practices driving the success of modern DevOps, helping teams automate infrastructure, reduce errors, and move faster.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What is Infrastructure as Code (IaC)?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Infrastructure as Code is the practice of managing and provisioning infrastructure (servers, databases, networks) using code instead of manual processes.&lt;/p&gt;

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

&lt;ul&gt;
&lt;li&gt;Clicking through dashboards&lt;/li&gt;
&lt;li&gt;Running manual commands&lt;/li&gt;
&lt;li&gt;Configuring servers one by one
You write code that defines your infrastructure, and tools automatically create and manage it for you.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;The Problem IaC Solves&lt;/strong&gt;&lt;br&gt;
Before IaC:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Infrastructure was set up manually&lt;/li&gt;
&lt;li&gt;Environments were inconsistent &lt;/li&gt;
&lt;li&gt;Deployments were slow and error-prone&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;IaC solves this by:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Making infrastructure repeatable and consistent&lt;/li&gt;
&lt;li&gt;Reducing human error&lt;/li&gt;
&lt;li&gt;Enabling automation and scalability&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Declarative vs Imperative Approaches&lt;/strong&gt;&lt;br&gt;
When working with IaC, there are two main approaches:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Imperative (How to do it)&lt;/strong&gt;&lt;br&gt;
You define step-by-step instructions.&lt;/p&gt;

&lt;p&gt;Example mindset:&lt;br&gt;
“First create a server, then install software, then configure it.”&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Similar to scripting (e.g., Bash, Python)&lt;/li&gt;
&lt;li&gt;More control, but harder to manage at scale&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Declarative (What you want)&lt;/strong&gt;&lt;br&gt;
You define the desired end state, and the tool figures out how to achieve it.&lt;/p&gt;

&lt;p&gt;Example mindset:&lt;br&gt;
“I want 2 servers running this application.”&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Simpler and more predictable&lt;/li&gt;
&lt;li&gt;Automatically handles changes and updates&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;💡 Most modern IaC tools—including Terraform—use the declarative approach, which is why they are so powerful.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Why Terraform is Worth Learning&lt;/strong&gt;&lt;br&gt;
Terraform has become one of the most popular IaC tools—and for good reason:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. Cloud-Agnostic&lt;/strong&gt;&lt;br&gt;
Works with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;AWS&lt;/li&gt;
&lt;li&gt;Azure&lt;/li&gt;
&lt;li&gt;Google Cloud&lt;/li&gt;
&lt;li&gt;And many others
You write once, deploy anywhere&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;2. Declarative and Simple&lt;/strong&gt;&lt;br&gt;
You define what you want, and Terraform handles the rest.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. Version Control for Infrastructure&lt;/strong&gt;&lt;br&gt;
Your infrastructure is stored as code:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Track changes&lt;/li&gt;
&lt;li&gt;Collaborate with teams&lt;/li&gt;
&lt;li&gt;Roll back when needed&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;4. Automation Friendly&lt;/strong&gt;&lt;br&gt;
Terraform integrates easily with CI/CD pipelines, making deployments faster and safer.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;5. Strong Community &amp;amp; Ecosystem&lt;/strong&gt;&lt;br&gt;
With a huge community and many reusable modules, you don’t have to start from scratch.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;My 30-Day Challenge Goals&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Go from beginner to confident in Infrastructure as Code.&lt;/li&gt;
&lt;li&gt;Build real projects, not just learn theory.&lt;/li&gt;
&lt;li&gt;Stay consistent and share my journey.&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>automation</category>
      <category>cloud</category>
      <category>devops</category>
    </item>
  </channel>
</rss>
