--experiment
Enables a specific experiment.
For a list of available experiments, see the experiments documentation.
Environment Variables:
TG_EXPERIMENT
The Terragrunt CLI supports the following global flags:
--experiment
Enables a specific experiment.
For a list of available experiments, see the experiments documentation.
Environment Variables:
TG_EXPERIMENT
--experiment-mode
Enables experiment mode for Terragrunt.
For more information, see the experiments documentation.
Environment Variables:
TG_EXPERIMENT_MODE
--log-custom-format
Set the custom log formatting.
For more information, see the log formatting documentation.
Environment Variables:
TG_LOG_CUSTOM_FORMAT
--log-disable
Disable logging.
When enabled, Terragrunt will disable all logging output. This is useful when you want to see only the OpenTofu/Terraform output or when using Terragrunt in scripts where logging isn’t needed.
Note that this automatically enables the --tf-forward-stdout
flag to ensure OpenTofu/Terraform output is still visible.
Environment Variables:
TG_LOG_DISABLE
--log-format
Set the format for Terragrunt's log output.
For a list of available formats and their descriptions, see the log formatting documentation.
Environment Variables:
TG_LOG_FORMAT
--log-level
Sets the logging level for Terragrunt.
Controls the verbosity of Terragrunt’s logging output. For more information about available log levels and their meanings, see the log levels documentation.
Environment Variables:
TG_LOG_LEVEL
--log-show-abs-paths
Show absolute paths in logs.
When enabled, Terragrunt will show absolute paths in log messages instead of relative paths.
For more information, see the log formatting documentation.
Environment Variables:
TG_LOG_SHOW_ABS_PATHS
--no-color
Disable color output for both Terragrunt and OpenTofu/Terraform.
When enabled, Terragrunt will disable colored output in both its own logs and in OpenTofu/Terraform output. This is useful when running in environments where color codes might cause issues, such as CI/CD pipelines or when redirecting output to files.
Environment Variables:
TG_NO_COLOR
--non-interactive
Assume "yes" for all prompts.
When enabled, Terragrunt will automatically answer “yes” to any prompts that would normally require user input. This is particularly useful in automated environments or CI/CD pipelines where user interaction isn’t possible.
Environment Variables:
TG_NON_INTERACTIVE
--strict-control
Enables specific strict controls.
Enables specific strict controls in Terragrunt. For a list of available controls and their descriptions, run terragrunt info strict
.
This flag provides finer-grained control compared to --strict-mode
, allowing you to enable specific controls rather than all of them.
For more information, see the strict controls documentation.
Environment Variables:
TG_STRICT_CONTROL
--strict-mode
Enables strict mode for Terragrunt.
When enabled, Terragrunt will operate in strict mode, which opts in the user to all future breaking changes. For more information about what strict mode enables, run terragrunt info strict
.
For more information about strict mode, see the strict controls documentation.
Environment Variables:
TG_STRICT_MODE
--working-dir
The path where all commands should be run. Default is current directory.
Specifies the working directory where Terragrunt should execute its commands. By default, Terragrunt uses the current directory.
Example:
terragrunt run plan --working-dir /path/to/infrastructure/prod
Environment Variables:
TG_WORKING_DIR
--help
Show help information.
Displays help information about Terragrunt commands and their usage. Can be used with specific commands to get detailed help about that command.
--version
Show terragrunt version.
Displays the current version of Terragrunt.