terraform

Solid

Terraform and OpenTofu configuration, modules, testing, state management, and HCL review. Use for "terraform module", "terraform test", "infrastructure as code", "IaC", "HCL", "tfvars", "terraform plan", "terraform apply", "OpenTofu", "tftest", or multi-environment patterns.

DevOps & Infrastructure 31 stars 3 forks Updated 1 weeks ago MIT

Install

View on GitHub

Quality Score: 82/100

Stars 20%
50
Recency 20%
90
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
80
License 10%
100
Description 5%
100

Skill Content

# Terraform & OpenTofu ## File Organization & Naming | File | Purpose | |------|---------| | `terraform.tf` | Terraform + provider version requirements | | `providers.tf` | Provider configurations | | `main.tf` | Primary resources and data sources | | `variables.tf` | Input variables (alphabetical) | | `outputs.tf` | Output values (alphabetical) | | `locals.tf` | Local values | - Lowercase with underscores: `web_api`, not `webAPI` or `web-api` - Descriptive nouns excluding resource type: `aws_instance.web_api` not `aws_instance.web_api_instance` - Singular, not plural - `this` for singleton resources (one of that type per module) - Contextual variable prefixes: `vpc_cidr_block` not `cidr` ## Block Ordering **Resources:** `count`/`for_each` (blank line after) → arguments → nested blocks → `tags` → `depends_on` → `lifecycle` (last) **Variables:** `description` → `type` → `default` → `validation` → `nullable` Every variable needs `type` + `description`. Every output needs `description`. Mark secrets `sensitive = true`. ## Module Structure | Type | Scope | Example | |------|-------|---------| | Resource Module | Single logical group | VPC + subnets, SG + rules | | Infrastructure Module | Collection of resource modules | Networking + compute for one region | | Composition | Complete infrastructure | Spans regions/accounts | ``` module-name/ ├── main.tf, variables.tf, outputs.tf, versions.tf ├── examples/ │ ├── minimal/ │ └── complete/ └── tests/ └── defaults.tfte...

Details

Author
iliaal
Repository
iliaal/whetstone
Created
6 months ago
Last Updated
1 weeks ago
Language
Python
License
MIT

Integrates with

Bundled in these plugins

Similar Skills

Semantically similar based on skill content — not just same category