terraform-skill

terraform-skill is a skill for Claude Code, Codex from beel-collab/presets.dev. It costs 6 tokens per session (3,877 once invoked), scanned A, a copy of terraform-skill, MIT.

A best-practices guide for Terraform and OpenTofu, tools that define cloud and other infrastructure in configuration files instead of manual setup.

In plain words
What is it for?
It is for creating or reviewing Terraform modules, testing infrastructure code, planning deployments, and managing state and multi-environment setups.
Why use it?
It helps structure infrastructure projects, choose testing methods, manage environments, and connect infrastructure changes to CI/CD pipelines.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit It is for creating or reviewing Terraform modules, testing infrastructure code, planning deployments, and managing state and multi-environment setups.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/beel-collab/presets.dev/terraform-skill
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add beel-collab/presets.dev --skill terraform-skill
Clone the repo
git clone --depth 1 https://github.com/beel-collab/presets.dev

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for terraform-skill

README.md
[![agentmods](https://agentmods.dev/badge/skills/beel-collab/presets.dev/terraform-skill.svg)](https://agentmods.dev/skills/beel-collab/presets.dev/terraform-skill)
Your own site
<a href="https://agentmods.dev/skills/beel-collab/presets.dev/terraform-skill"><img src="https://agentmods.dev/badge/skills/beel-collab/presets.dev/terraform-skill.svg" alt="Measured on agentmods" height="20"></a>
Per session 6 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,877 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin 88% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00006 $0.03877
Opus 5 $0.00003 $0.01938
Sonnet 5 $0.00001 $0.00775
Haiku 4.5 $0.00001 $0.00388

Measured 4d ago against content hash f5ebdc34472a, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

terraform-skill scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

This is a copy

88% identical to terraform-skill — 15 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

claude/skills/devops/terraform-skill/SKILL.md · 522 lines

How it starts

The opening of the file, as written. The whole thing — 522 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Terraform Skill for Claude

Comprehensive Terraform and OpenTofu guidance covering testing, modules, CI/CD, and production patterns. Based on terraform-best-practices.com and enterprise experience.

When to Use This Skill

Activate this skill when:

  • Creating new Terraform or OpenTofu configurations or modules
  • Setting up testing infrastructure for IaC code
  • Deciding between testing approaches (validate, plan, frameworks)
  • Structuring multi-environment deployments
  • Implementing CI/CD for infrastructure-as-code
  • Reviewing or refactoring existing Terraform/OpenTofu projects
  • Choosing between module patterns or state management approaches

Don't use this skill for:

  • Basic Terraform/OpenTofu syntax questions (Claude knows this)
  • Provider-specific API reference (link to docs instead)
  • Cloud platform questions unrelated to Terraform/OpenTofu

Core Principles

1. Code Structure Philosophy

Module Hierarchy:

Type When to Use Scope
Resource Module Single logical group of connected resources VPC + subnets, Security group + rules
Infrastructure Module Collection of resource modules for a purpose Multiple resource modules in one region/account
Composition Complete infrastructure Spans multiple regions/accounts

Hierarchy: Resource → Resource Module → Infrastructure Module → Composition

Directory Structure:

environments/        # Environment-specific configurations
├── prod/
├── staging/
└── dev/

modules/            # Reusable modules
├── networking/
├── compute/
└── data/

examples/           # Module usage examples (also serve as tests)
├── complete/
└── minimal/

Key principle from terraform-best-practices.com:

  • Separate environments (prod, staging) from modules (reusable components)
  • Use examples/ as both documentation and integration test fixtures
  • Keep modules small and focused (single responsibility)

For detailed module architecture, see: Code Patterns: Module Types & Hierarchy

Read the full file on GitHub · 522 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 522 lines · 6 tokens per session scan A f5ebdc34472a

Subscribe to this mod's changes

terraform-skill is a skill published in the GitHub repository beel-collab/presets.dev (2 stars, last pushed 4mo ago), licensed MIT. It adds 6 tokens to every session and 3,877 once invoked, about $0.0000 per session on Opus 5. A static security scan graded it A with 0 findings. It is 88% identical to terraform-skill, differing in 15 lines, and is treated as a copy.

Related

Other skills, from other repositories

deepeval

Use when discussing or working with DeepEval (the python AI evaluation framework).

sammcj/agentic-coding · 19 tokens

iterative-refinement

Disciplined, measurable iteration for a substantial refinement or investigation: loop against verifiable pass/fail conditions, fan work out to subagents, and keep the main context lean. Use when improving something measurable over repeated cycles (tuning a metric or detector, refactoring against a regression bar)…

sammcj/agentic-coding · 100 tokens

diagnose-hard-problem

Disciplined diagnosis loop for hard problems, diagnosing bugs and regressions. Reproduce → minimise → hypothesise → instrument → fix → regression-test.

sammcj/agentic-coding · 37 tokens

godot-export

Export and build a Godot 4.7 project for distribution: install export templates, define export presets (Windows/macOS/Linux/Web/Android), run headless command-line exports for CI, and handle web (HTML5) COOP/COEP and dedicated-server/headless builds. Use when exporting a Godot game, configuring exportpresets.cfg…

gamedev-skills/awesome-gamedev-agent-skills · 92 tokens

skill-creator-primer

You MUST load this skill before the skill-creator skill AND before making ANY change to, or conducting a review of ANY Agent Skill. Triggers include creating, editing, reviewing, or contributing to any part of an Agent Skill (description, frontmatter, body, references, scripts, trigger evals, conflicts, etc).

sammcj/agentic-coding · 74 tokens

llm-wiki

Use when building or maintaining a self-contained personal knowledge base (an LLM wiki) in plain markdown. Triggers: ingesting sources into a wiki, querying wiki knowledge, linting wiki health, auditing article claims against their sources, critiquing a wiki source's reasoning, superseding stale knowledge, 'add to…

sammcj/agentic-coding · 82 tokens