/ 디렉터리 / 플레이그라운드 / terraform-skill
● 커뮤니티 antonbabenko ⚡ 바로 사용

terraform-skill

제작: antonbabenko · antonbabenko/terraform-skill

Maintained by Anton Babenko — Terraform and OpenTofu patterns from terraform-best-practices.com and terraform-aws-modules, with when-and-why decision frameworks.

A Claude agent skill for Terraform/OpenTofu work. Teaches Claude to choose between native Terraform tests (1.6+) and Terratest, structure modules like terraform-aws-modules, wire up GitHub Actions / GitLab CI with cost estimation and security scanning, and apply production patterns. Explains not just 'what' but 'when and why'.

왜 쓰나요

핵심 기능

라이브 데모

실제 사용 모습

terraform-skill.replay ▶ 준비됨
0/0

설치

작성자 저장소 · Claude Skills 공식 문서

사용 사례

실전 활용법: terraform-skill

Scaffold a new Terraform module the idiomatic way

👤 Platform engineers publishing a reusable module ⏱ ~45 min intermediate

언제 쓸까: You're splitting out a module for internal or public reuse and want the structure right the first time.

흐름
  1. State the module's purpose
    Use the terraform-skill. Scaffold a module for an AWS ECS service with optional ALB and CloudWatch alarms.✓ 복사됨
    → Structure follows terraform-aws-modules conventions — main.tf, variables.tf, outputs.tf, versions.tf, README.md, examples/
  2. Add tests
    Recommend tests — native or Terratest? Apply the decision framework.✓ 복사됨
    → Reasoned choice and scaffolded test files

결과: A module that passes review on the first PR.

함정
  • Versioning too loose (~> vs specific) — Skill defaults to pinned minors for required_providers
함께 쓰기: github

Add a hardened CI pipeline to an existing Terraform repo

👤 DevOps / platform engineers ⏱ ~40 min advanced

언제 쓸까: Your repo lacks plan-on-PR, cost checks, or security scans.

사전 조건
  • GitHub or GitLab hosting — For the respective pipeline template
흐름
  1. Request the pipeline
    Use terraform-skill. Add GitHub Actions for plan-on-PR, Infracost, tfsec, and gated apply on main.✓ 복사됨
    → Workflow files with concurrency guards, OIDC auth, status checks
  2. Security tune
    Which Checkov / tfsec rules should we fail on vs warn?✓ 복사됨
    → Opinionated list with rationale

결과: A pipeline that blocks risky changes without slowing everyone down.

함정
  • Pipeline uses long-lived AWS keys — Skill prefers OIDC/role assumption, not static keys
함께 쓰기: github

Design a multi-environment layout without state explosions

👤 Teams scaling from dev/prod to dev/staging/prod/per-tenant ⏱ ~60 min advanced

언제 쓸까: You feel the pain of copy-pasted env folders or a monolith state.

흐름
  1. Describe the envs
    Use terraform-skill. We need dev/staging/prod plus per-tenant envs. What layout scales?✓ 복사됨
    → Recommendation with tradeoffs (workspaces vs dirs vs Terragrunt)
  2. Plan the migration
    We're currently on a single state. Sketch the migration.✓ 복사됨
    → State-move plan with risk callouts

결과: A layout you can defend in an ADR.

함정
  • Moving state without imports/breakdowns can destroy resources — The skill insists on terraform state mv / import steps, not delete-and-recreate

조합

다른 MCP와 조합해 10배 효율

terraform-skill + github

Skill produces module + workflow; GitHub MCP opens the PR

Scaffold the module, add the workflow, open a PR into our platform repo.✓ 복사됨
terraform-skill + aws

Cross-check the Terraform plan against live AWS state

Show me the plan, then diff against actual resources via the AWS MCP.✓ 복사됨

도구

이 MCP가 노출하는 것

도구입력언제 호출비용
Module scaffolding module purpose + provider Starting a new module 0
Test strategy advisor module scope Adding test coverage 0
CI pipeline templates (GHA / GitLab) hosting choice Setting up CI for a repo 0
Pattern compare a snippet Reviewing existing code 0

비용 및 제한

운영 비용

API 쿼터
None
호출당 토큰
2-6k per session — moderate
금액
Free — skill is local
팁
Ask one focused question (testing / CI / layout) at a time.

보안

권한, 시크릿, 파급범위

자격 증명 저장: No credentials in the skill. Any provider creds belong in your env, not the generated code.
데이터 외부 송신: None from the skill itself

문제 해결

자주 발생하는 오류와 해결

Skill's suggestion conflicts with your org's style

Provide your .terraform-docs config and existing module as style anchors.

Recommended OIDC setup fails on assume-role

Check the trust policy's sub condition matches your branch/env.

대안

terraform-skill 다른 것과 비교

대안언제 쓰나단점/장점
Terragrunt-first skillsYou're committed to TerragruntLess coverage here; Terragrunt workflows differ substantially
Cloud-provider-native IaC skills (aws-cdk, pulumi)You're not on Terraform/OpenTofuDifferent tool, different patterns

더 보기

리소스

📖 GitHub에서 공식 README 읽기

🐙 열린 이슈 보기

🔍 400+ MCP 서버 및 Skills 전체 보기