terragrunt-generator

Generate Terragrunt HCL configurations with dependency wiring and safety checks.

Updated Apr 15, 2026
One-click install
npx skills add https://github.com/ToanPV90/dotfiles --skill terragrunt-generator-toanpv90
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: terragrunt-generator
Source: https://github.com/ToanPV90/dotfiles/tree/main/claude/.claude/skills/terragrunt-generator
Command: npx skills add https://github.com/ToanPV90/dotfiles --skill terragrunt-generator-toanpv90

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill solves the problem of hand-authoring error-prone Terragrunt HCL by generating consistent, production-ready configurations from best-practice patterns.

Core Features & Use Cases

  • Terragrunt scaffolding with modern conventions: Generates root.hcl (favoring find_in_parent_folders("root.hcl")), child terragrunt.hcl, and multi-environment layouts.
  • Dependency wiring and safe validation: Produces dependency blocks with mock_outputs and mock_outputs_allowed_terraform_commands to keep validate/plan workflows unblocked.
  • 2025 feature support with guardrails: Supports Stacks, Feature Flags, exclude blocks, errors blocks, and OpenTofu engine patterns while avoiding deprecated attributes.
  • Built-in safety checks: Ensures encrypt=true for remote_state, uses errors blocks instead of retryable_errors, performs placeholder and secrets safety checks, and runs validation (or fallback checks) before presenting results.

Quick Start

Use the terragrunt-generator Skill to generate a multi-environment Terragrunt setup with correct root include syntax, dependency wiring with mock outputs, and 2025-ready feature flags for your new infrastructure project.

Frequently Asked Questions about terragrunt-generator

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

FAQPage Schema
How do I generate a multi-environment Terragrunt configuration for dev, staging, and prod?

To generate multi-environment Terragrunt configurations, scaffold a root.hcl file using find_in_parent_folders, create child terragrunt.hcl files, and wire dependencies with mock outputs to keep validate and plan workflows unblocked across dev, staging, and prod environments.

How do I set up dependency wiring with mock outputs in Terragrunt?

Set up dependency wiring in Terragrunt by configuring dependency blocks with mock_outputs and mock_outputs_allowed_terraform_commands, ensuring validate and plan workflows remain unblocked even when upstream infrastructure modules are not yet deployed or available.

What is the correct way to use feature flags and exclude blocks in Terragrunt HCL?

Feature flags and exclude blocks in Terragrunt HCL are modern 2025 features that control module execution and skip configurations conditionally, replacing deprecated attributes while applying built-in guardrails to ensure correct syntax and safe infrastructure as code operations.

Does this Terragrunt generator support OpenTofu engine patterns and Stacks?

Yes, this Terragrunt generator supports OpenTofu engine patterns and Stacks, applying correct Terragrunt include and engine feature requirements while avoiding deprecated attributes to ensure your infrastructure as code remains 2025-ready and production-safe.

Why should I use errors blocks instead of retryable_errors in Terragrunt?

You should use errors blocks instead of retryable_errors because errors blocks represent modern 2025 Terragrunt conventions, providing built-in safety checks and validation guardrails that ensure placeholder and secrets safety while maintaining production-ready infrastructure configurations.

Can I ensure encrypt=true for remote state when scaffolding Terragrunt projects?

Yes, built-in safety checks enforce encrypt=true for remote_state configurations when scaffolding Terragrunt projects, performing placeholder and secrets safety checks alongside validation guardrails to ensure your generated HCL meets production-ready security standards.