본문으로 건너뛰기
Skillpedia
배포 및 클라우드 (DevOps)40k · #7449

terraform-azurerm-set-diff-analyzer

하는 일

이 도구는 Azure 리소스의 Terraform 계획 출력을 분석합니다. 일부 Azure 리소스가 항목 목록을 처리하는 방식 때문에 생기는, 크게 보이지만 실제로는 사소하거나 아예 없는 변경을 찾아냅니다.

사용하는 경우

  • ✓`terraform plan`에 많은 변경이 나타났지만 실제로는 항목 하나만 추가하거나 제거했을 때.
  • ✓Application Gateway나 Load Balancer 같은 리소스가 'all elements changed'를 보여 줄 때.
  • ✓자동화 과정(CI/CD)에서 거짓 변경을 자동으로 걸러내고 싶을 때.

스킬 링크

https://github.com/github/awesome-copilot/blob/main/skills/terraform-azurerm-set-diff-analyzer/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/github/awesome-copilot/blob/main/skills/terraform-azurerm-set-diff-analyzer/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“제 Terraform 계획을 분석해서 어떤 변경이 실제이고 어떤 변경이 거짓인지 알려 주세요.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

도구는 Terraform 계획 출력을 이런 '거짓 변경'을 일으키는 것으로 알려진 리소스와 속성 목록과 비교합니다. 항목 순서 문제를 일으키는 'Set' 타입 속성에 집중합니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Terraform AzureRM Set Diff Analyzer

A skill to identify "false-positive diffs" in Terraform plans caused by AzureRM Provider's Set-type attributes and distinguish them from actual changes.

When to Use

  • terraform plan shows many changes, but you only added/removed a single element
  • Application Gateway, Load Balancer, NSG, etc. show "all elements changed"
  • You want to automatically filter false-positive diffs in CI/CD

Background

Terraform's Set type compares by position rather than by key, so when adding or removing elements, all elements appear as "changed". This is a general Terraform issue, but it's particularly noticeable with AzureRM resources that heavily use Set-type attributes like Application Gateway, Load Balancer, and NSG.

These "false-positive diffs" don't actually affect the resources, but they make reviewing terraform plan output difficult.

Prerequisites

  • Python 3.8+

If Python is unavailable, install via your package manager (e.g., apt install python3, brew install python3) or from python.org.

Basic Usage

# 1. Generate plan JSON output
terraform plan -out=plan.tfplan
terraform show -json plan.tfplan > plan.json

# 2. Analyze
python scripts/analyze_plan.py plan.json

Troubleshooting

  • python: command not found: Use python3 instead, or install Python
  • ModuleNotFoundError: Script uses only standard library; ensure Python 3.8+

Detailed Documentation

자주 묻는 질문

'거짓 변경'이란 무엇인가요?

Terraform 계획에는 보이지만 실제로 Azure의 리소스를 바꾸지 않는 변경입니다. 일부 목록에서 항목의 순서를 비교하기 때문에 생깁니다.

설치해야 할 것이 있나요?

네, 컴퓨터에 Python 3.8 이상이 설치되어 있어야 합니다.

어떻게 사용하나요?

먼저 Terraform 계획 파일을 생성합니다(`terraform plan -out=plan.tfplan` 및 `terraform show -json plan.tfplan > plan.json`). 그다음 생성된 파일로 Python 스크립트를 실행합니다(`python scripts/analyze_plan.py plan.json`).

상세 정보

작성자의 원본 설명

Analyze Terraform plan JSON output for AzureRM Provider to distinguish between false-positive diffs (order-only changes in Set-type attributes) and actual resource changes. Use when reviewing terraform plan output for Azure resources like Application Gateway, Load Balancer, Firewall, Front Door, NSG, and other resources with Set-type attributes that cause spurious diffs due to internal ordering ch

repo: github/awesome-copilot

인기도

GitHub 스타
40k
순위
#7449
라이선스
MIT
업데이트
2026. 10. 15.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬