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.
npx agentmods add skills/soulcodex/agentic/terraform-infrastructurenpx skills add soulcodex/agentic --skill terraform-infrastructuregit clone --depth 1 https://github.com/soulcodex/agenticWrote 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.
[](https://agentmods.dev/skills/soulcodex/agentic/terraform-infrastructure)<a href="https://agentmods.dev/skills/soulcodex/agentic/terraform-infrastructure"><img src="https://agentmods.dev/badge/skills/soulcodex/agentic/terraform-infrastructure.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00096 | $0.03501 |
| Opus 5 | $0.00048 | $0.01750 |
| Sonnet 5 | $0.00019 | $0.00700 |
| Haiku 4.5 | $0.00010 | $0.00350 |
Grade A, and why
terraform-infrastructure 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 5d 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.
How it starts
The opening of the file, as written. The whole thing — 465 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Terraform Infrastructure Skill
Always use terraform-risk-playbook first when this skill is active. That
skill is authoritative for the response contract, risk classification,
runtime/version assumptions, validation commands, and rollback notes.
Authoritative precedence: when this skill and other Terraform skills are both active, this skill is authoritative for repo and stack layout, backend topology, CI composition, and multi-region deployment structure.
Step 1 — Module Structure
Organise Terraform code into reusable modules:
infra/
modules/
vpc/
main.tf
variables.tf
outputs.tf
rds/
main.tf
variables.tf
outputs.tf
ecs-service/
main.tf
variables.tf
outputs.tf
environments/
staging/
main.tf ← calls modules, sets env-specific vars
terraform.tfvars ← non-secret values only
backend.tf ← remote state config
production/
main.tf
terraform.tfvars
backend.tf
Rules:
- Every module has exactly three files:
main.tf,variables.tf,outputs.tf. - Modules accept inputs via
variables.tfand expose results viaoutputs.tf. - Never put environment-specific config inside a module.
Step 2 — Remote State
Use S3 remote state for AWS. Prefer native S3 lock files on Terraform 1.10+ and fall back to DynamoDB locking only for older runtime compatibility:
# environments/staging/backend.tf
terraform {
backend "s3" {
bucket = "acme-terraform-state"
key = "staging/terraform.tfstate"
region = "us-east-1"
encrypt = true
use_lockfile = true
}
}
State bucket requirements:
- Versioning enabled.
- Server-side encryption enabled (SSE-S3 or SSE-KMS).
- Block all public access.
- Access restricted to CI role and infrastructure team.
If the runtime is older than Terraform 1.10, replace use_lockfile = true with
dynamodb_table = "acme-terraform-locks" and state that compatibility choice
explicitly.
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.
- 5d ago First seen · 465 lines · 96 tokens per session scan A a16eb64c615e
terraform-infrastructure is a skill published in the GitHub repository soulcodex/agentic (10 stars, last pushed 4d ago), licensed MIT. It adds 96 tokens to every session and 3,501 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
Cloud Security & Container Hardening
AWS/Azure/GCP security auditing, container and Kubernetes hardening, Infrastructure as Code scanning, and cloud compliance assessment.
terraform
Terraform infrastructure-as-code workflow patterns: state and environments, module design, safe plan/apply, drift control, and CI guardrails.
GCP Architecture Framework Pillar Review
Google Cloud Architecture Framework pillar checklists — operational excellence, security/privacy/compliance, reliability, cost optimization, performance optimization, sustainability — for reviewing GCP infrastructure changes.
AWS WAF Pillar Review
AWS Well-Architected Framework pillar checklists — operational excellence, security, reliability, performance efficiency, cost optimization, sustainability — for reviewing AWS infrastructure changes.
Azure WAF Pillar Review
Azure-specific Well-Architected Framework pillar checklists — reliability, security, cost optimization, operational excellence, performance efficiency — for reviewing Azure infrastructure changes.
Well-Architected Pillar Review
A discipline for mapping any nontrivial infrastructure change to the standard architecture pillars — security, reliability, cost, operational excellence, performance — regardless of cloud provider.