iac

Write and review Terraform infrastructure code for AWS, Azure, and GCP.

Updated May 8, 2026
One-click install
npx skills add https://github.com/kiprotichgidii/agent-skills --skill iac-kiprotichgidii
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: iac
Source: https://github.com/kiprotichgidii/agent-skills/tree/main/skills/infrastructure-as-code
Command: npx skills add https://github.com/kiprotichgidii/agent-skills --skill iac-kiprotichgidii

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires terraform, aws-cli, azure-cli, gcloud.

What problem does it solve? Writing and maintaining Terraform configurations across multiple cloud providers is error-prone, and mistakes like misused lifecycle rules or hardcoded secrets can cause drift, security gaps, and unpredictable infrastructure. ## Core Features & Use Cases - Terraform Best Practices: Enforces module structure, remote state management, typed variables, naming conventions, and proper resource dependencies. - Multi-Cloud Provider Patterns: Applies provider-specific guidance for AWS, Azure, and GCP including tagging, IAM, managed identities, and service accounts. - Safety Guardrails: Blocks unapproved use of lifecycle.ignore_changes, escalates destructive changes, and enforces security practices like encryption and least privilege. - Use Case: When asked to provision an AWS VPC with subnets and an EC2 instance, the Skill generates well-structured HCL with validated variables, outputs, remote state configuration, and a plan review before apply. ## Quick Start Use the iac skill to write a Terraform module that provisions an AWS VPC with public and private subnets following best practices.

Frequently Asked Questions about iac

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I write Terraform code for AWS, Azure, or GCP?▼

Define typed variables with validation, organize resources into reusable modules, and use provider-specific data sources instead of hardcoded values. Follow each provider's conventions such as AWS tagging, Azure resource groups, and GCP service accounts with minimal permissions.

How to structure Terraform modules for multiple environments?▼

Use workspaces or separate state keys per environment with a remote backend like S3, and compose modules with explicit inputs and outputs. Pass environment-specific values through variables and wire dependencies between modules using depends_on.

Why is lifecycle.ignore_changes dangerous in Terraform?▼

ignore_changes masks configuration drift so Terraform shows no changes while actual infrastructure differs from code. It hides root causes like external modification or misconfiguration, so alternatives like data sources, create_before_destroy, or resource imports should be used instead.

Does Terraform support importing existing cloud resources?▼

Yes, terraform import brings existing brownfield infrastructure under Terraform management by mapping real resources to configuration blocks. This is preferred over ignoring drift when resources are managed by multiple systems.

What security practices should Terraform configurations follow?▼

Enable encryption at rest and in transit, apply least-privilege IAM permissions, never hardcode secrets, and configure network controls like security groups and firewalls. Enable audit logging and validate plans for open access before applying.