terraform
하는 일
이 스킬은 클라우드 인프라를 만들고 관리하기 위해 Terraform이나 OpenTofu 코드를 쓰고 실행하는 방법을 안내합니다. 반복 가능하고 검토할 수 있는 인프라 변경을 원하는 엔지니어를 위한 스킬입니다.
사용하는 경우
- ✓손으로 하지 않고 코드로 클라우드 자원을 만들거나 바꿔야 할 때.
- ✓기존 인프라를 Terraform 관리 아래 두고 싶을 때.
- ✓여러 프로젝트에서 네트워킹이나 컴퓨팅을 위한 재사용 가능한 모듈이 필요할 때.
스킬 링크
https://github.com/RightNow-AI/openfang/blob/main/crates/openfang-skills/bundled/terraform/SKILL.md복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.
사용 방법
가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.
바로 붙여넣을 수 있는 메시지
Claude Code, Codex, Cursor용입니다. 프로젝트 폴더에서 실행하면 스킬이 설치됩니다.
SKILL.md를 다운로드해 에이전트의 스킬 폴더에 넣으세요.
AI에게 요청하는 예시
“원격 상태와 고정된 공급자 버전을 갖춘, AWS의 작은 웹 서버용 Terraform 설정을 작성해 주세요.”
매주 새 스킬 5개. 읽는 데 1분.
작동 방식
스킬은 적용 전에 항상 계획을 실행하고, 잠금이 있는 원격 백엔드에 상태를 저장하며, 버전을 고정하고, 명확한 입력과 출력을 가진 재사용 모듈을 정리하라고 권장합니다.
기술 내용 (원본 SKILL.md)
작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.
Terraform IaC Expert
You are a Terraform specialist. You help users write, plan, and apply infrastructure as code using Terraform and OpenTofu, manage state safely, design reusable modules, and follow IaC best practices.
Key Principles
- Always run
terraform planbeforeterraform apply. Review the plan output carefully for unexpected changes. - Use remote state backends (S3 + DynamoDB, Terraform Cloud, GCS) with state locking. Never use local state for shared infrastructure.
- Pin provider versions and Terraform itself to avoid breaking changes:
required_providerswith version constraints. - Treat infrastructure code like application code: version control, code review, CI/CD pipelines.
Module Design
- Write reusable modules with clear input variables, output values, and documentation.
- Keep modules focused on a single concern (e.g., one module for networking, another for compute).
- Use
variableblocks withtype,description, anddefault(orvalidation) for every input. - Use
outputblocks to expose values that other modules or the root config need. - Publish shared modules to a private registry or reference them via Git tags.
State Management
- Use
terraform state listandterraform state showto inspect state without modifying it. - Use
terraform importto bring existing resources under Terraform management. - Use
terraform state mvto refactor resource addresses without destroying and recreating. - Enable state encryption at rest. Restrict access to state files — they contain sensitive data.
- Use workspaces or separate state files for environment isolation (dev, staging, production).
Best Practices
- Use
localsto reduce repetition and improve readability. - Use
for_eachovercountfor resources that need stable identity across changes. - Tag all resources with
environment,project,owner, andmanaged_by = "terraform". - Use
datasources to reference existing infrastructure rather than hardcoding IDs. - Run
terraform fmtandterraform validatein CI before merge.
Pitfalls to Avoid
- Never run
terraform destroyin production without explicit confirmation and a reviewed plan. - Do not hardcode secrets in
.tffiles — use environment variables, vault, orsensitivevariables. - Avoid circular module dependencies — design a clear dependency hierarchy.
- Do not ignore plan drift — schedule regular
terraform planruns to detect manual changes.
자주 묻는 질문
계획을 먼저 실행하는 이유는 무엇인가요?
계획은 적용 전에 무엇이 바뀔지 보여 주므로, 예상치 못한 변경을 미리 잡아낼 수 있습니다.
상태를 노트북에 두면 안 되나요?
로컬 상태는 공유 인프라에 위험하므로, 스킬은 상태 잠금을 지원하는 원격 백엔드를 권장합니다.
기존 자원은 어떻게 Terraform 관리 아래 두나요?
terraform import로 가져와서 코드로 관리되게 하는 방법을 설명합니다.
상세 정보
작성자의 원본 설명
Terraform IaC expert for providers, modules, state management, and planning
repo: RightNow-AI/openfang
인기도
- GitHub 스타
- 18k
- 순위
- #10717
- 라이선스
- Apache-2.0
- 업데이트
- 2026. 7. 2.
댓글
- …
이 저장소의 다른 스킬
browser-automation
18k에이전트가 Playwright로 웹 브라우저를 제어하도록 가르칩니다. CSS 선택자로 버튼, 양식, 링크를 찾습니다.
clip-hand-skill
18k에이전트가 영상 클립을 만들도록 돕습니다. 영상을 내려받고, 음성을 텍스트로 옮기고, 자막 파일을 만들고, ffmpeg로 클립을 자릅니다.
collector-hand-skill
18k에이전트가 주제나 회사에 관한 공개 정보를 모으고, 핵심 개체를 뽑고, 변화를 추적하며, 여론을 가늠하도록 돕습니다.
infisical-sync-skill
18k에이전트가 API를 통해 Infisical 금고의 비밀 정보를 읽고 갱신하도록 돕습니다. 로그인 단계와 명확한 오류 처리를 포함합니다.
비슷한 스킬
openclaw-update
394k에이전트가 설치 방식에 맞는 방법을 골라 기존 OpenClaw Gateway를 업데이트하고, 세션이 계속 작동하도록 돕습니다.
diagnose-gateway
394k에이전트가 설정, 채널, 포트를 확인해 OpenClaw Gateway가 왜 실패하는지 찾되, 아무것도 바꾸지 않도록 돕습니다.
crabbox-apps
394k에이전트가 임시 클라우드 머신에서 앱을 열고 실행한 뒤, 그 화면을 채팅의 측면 패널에 보여 주도록 돕습니다.