terraform-style-guide

Generate and validate Terraform HCL code against HashiCorp style and security standards.

Updated Jul 20, 2026
One-click install
npx skills add https://github.com/kk0ga/terraform-aws-learning --skill terraform-style-guide-kk0ga
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: terraform-style-guide
Source: https://github.com/kk0ga/terraform-aws-learning/tree/main/.agents/skills/terraform-style-guide
Command: npx skills add https://github.com/kk0ga/terraform-aws-learning --skill terraform-style-guide-kk0ga

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill addresses the inconsistency and security risks often found in Infrastructure as Code by enforcing HashiCorp's official style conventions and security best practices.

Core Features & Use Cases

  • Standardized Formatting: Ensures all Terraform configurations follow consistent indentation, block organization, and naming conventions.
  • Security Hardening: Automatically applies best practices like encryption at rest, principle of least privilege, and sensitive data management using ephemeral resources.
  • Use Case: When building a new AWS infrastructure module, use this Skill to ensure your variables, outputs, and resource blocks are structured correctly and that sensitive credentials are never exposed in the state file.

Quick Start

Use the terraform-style-guide skill to review the current directory for adherence to HashiCorp style conventions and security standards.

Frequently Asked Questions about terraform-style-guide

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I enforce HashiCorp style conventions and security standards in Terraform?

To enforce HashiCorp style conventions in Terraform, this skill validates HCL code for consistent indentation, block organization, secure secret handling, and modular code organization.

What is the best way to secure sensitive data in Terraform HCL configurations?

Securing sensitive data in Terraform involves applying security hardening practices like encryption at rest, least privilege, and sensitive data management using ephemeral resources to prevent credentials from being exposed in the state file.

How do I standardize formatting for AWS infrastructure modules in Terraform?

Standardizing formatting for AWS infrastructure modules requires ensuring all Terraform configurations follow consistent indentation, block organization, and naming conventions according to official style guidelines.

Does this Terraform style guide work for reviewing existing root configurations?

Yes, this Terraform style guide works for reviewing existing root configurations, applying to the creation, review, and refactoring of infrastructure modules to ensure they adhere to security hardening requirements.

Can I use this to check Terraform code for adherence to HashiCorp style conventions?

Yes, you can use this to check Terraform code for adherence to HashiCorp style conventions by reviewing your current directory to validate HCL code against official style and security standards.