Terraform Infrastructure
Published by aj-geddes in useful-ai-prompts
Review recommended618 installs
What this skill does
>
Add Terraform Infrastructure to your agent
Review the source and files first. When you are ready, copy the prompt instruction or use the CLI command supported by your environment.
Install with a prompt
Paste this into a compatible coding agent:
add this skill "terraform-infrastructure" from https://github.com/aj-geddes/useful-ai-promptsInstall with the CLI
Run this command in a controlled environment after reviewing the repository:
npx skills add https://github.com/aj-geddes/useful-ai-prompts --skill terraform-infrastructureSkill instructions
Terraform Infrastructure
Table of Contents
Overview
Build scalable infrastructure as code with Terraform, managing AWS, Azure, GCP, and on-premise resources through declarative configuration, remote state, and automated provisioning.
When to Use
- Cloud infrastructure provisioning
- Multi-environment management (dev, staging, prod)
- Infrastructure versioning and code review
- Cost tracking and resource optimization
- Disaster recovery and environment replication
- Automated infrastructure testing
- Cross-region deployments
Quick Start
Minimal working example:
# terraform/main.tf
terraform {
required_version = ">= 1.0"
required_providers {
aws = {
source = "hashicorp/aws"
version = "~> 5.0"
}
}
# Remote state configuration
backend "s3" {
bucket = "terraform-state-prod"
key = "prod/terraform.tfstate"
region = "us-east-1"
encrypt = true
dynamodb_table = "terraform-locks"
}
}
provider "aws" {
region = var.aws_region
default_tags {
// ... (see reference guides for full implementation)
Reference Guides
Detailed implementations in the references/ directory:
| Guide | Contents |
|---|---|
| AWS Infrastructure Module | AWS Infrastructure Module |
| Variables and Outputs | Variables and Outputs |
| Terraform Deployment Script | Terraform Deployment Script |
Best Practices
✅ DO
- Use remote state (S3, Terraform Cloud)
- Implement state locking (DynamoDB)
- Organize code into modules
- Use workspaces for environments
- Apply tags consistently
- Use variables for flexibility
- Implement code review before apply
- Keep sensitive data in separate variable files
❌ DON'T
- Store state files locally in git
- Use hardcoded values
- Mix environments in single state
- Skip terraform plan review
- Use root module for everything
- Store secrets in code
- Disable state locking
Files included
- references/aws-infrastructure-module.md
- references/terraform-deployment-script.md
- references/variables-and-outputs.md
- scripts/validate-config.sh
- SKILL.md
- templates/config-starter.yaml
More skills
Terraform Infrastructure As Code
manutej/luxor-claude-marketplace
No summary provided.
Audit unavailable390 installsTerraform Deployer
nvidia/skillspector
No summary provided.
Audit unavailable196 installsAuditing Terraform Infrastructure For Security
mukul975/anthropic-cybersecurity-skills
No summary provided.
Audit unavailable266 installs

