You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* fix: Cleaning up overview
* feat: Adding global flags and resolving a bit more of the gaps in the docs before fleshing out content for CLI
* fix: Fixing links
* fix: Removing hanging thought
* fix: Adding URL validation for link in flags
* fix: Making examples mandatory
* fix: Nits from CodeRabbit
* fix: Adding some whitespace after headings
* fix: Adding migration guide for cli-redesign
* fix: Nit from CodeRabbit
* fix: Adding mechanism for flag data lookup
* fix: Addressing nits
* feat: Add flags as data for all flags
* fix: Fixing env var in legacy docs
* fix: Fixing some typos in the old docs
* fix: Reworking all flags so that they offer rich information
* fix: Fixing all broken links for `cli-options`
* fix: Adding redirects for old routes
* fix: Adding docs for the `unit` block
* Delete astro.config.mjs
Copy file name to clipboardexpand all lines: docs-starlight/src/content/docs/01-getting-started/01-quick-start.mdx
+1-1
Original file line number
Diff line number
Diff line change
@@ -46,7 +46,7 @@ This tutorial will not assume the following:
46
46
2. You have any experience with Terragrunt.
47
47
3. You have any existing Terragrunt, OpenTofu or Terraform projects.
48
48
49
-
\* Note that if you have _both_ OpenTofu and Terraform installed, you'll want to read the [tf-path](/docs/reference/cli-options/#tf-path) docs to understand how Terragrunt determines which binary to use.
49
+
\* Note that if you have _both_ OpenTofu and Terraform installed, you'll want to read the [tf-path](/docs/reference/cli/commands/run#tf-path) docs to understand how Terragrunt determines which binary to use.
50
50
51
51
If you would like a less gentle introduction geared towards users with an active AWS account, familiarity with OpenTofu/Terraform, and potentially a team actively using Terragrunt, consider starting with the [Overview](/docs/getting-started/overview/).
Copy file name to clipboardexpand all lines: docs-starlight/src/content/docs/01-getting-started/04-terminology.md
+7-7
Original file line number
Diff line number
Diff line change
@@ -48,7 +48,7 @@ While not a requirement, a general tendency experienced when working with Terrag
48
48
49
49
A common pattern used in the repository structure for Terragrunt projects is to have a single `terragrunt.hcl` file located at the root of the repository, and multiple subdirectories each containing their own `terragrunt.hcl` file. This is typically done to promote code-reuse, as it allows for any configuration common to all units to be defined in the root `terragrunt.hcl` file, and for unit-specific configuration to be defined in child directories. In this pattern, the root `terragrunt.hcl` file is not considered a unit, while all the child directories containing `terragrunt.hcl` files are.
50
50
51
-
Note that units don't technically need to call their configuration files `terragrunt.hcl` (that's configurable via the [--config](/docs/reference/cli-options/#config)), and users don't technically need to use a root `terragrunt.hcl` file or to name it that. This is the most common pattern followed by the community, however, and deviation from this pattern should be justified in the context of the project. It can help others with Terragrunt experience understand the project more easily if industry standard patterns are followed.
51
+
Note that units don't technically need to call their configuration files `terragrunt.hcl` (that's configurable via the [--config](/docs/reference/cli/commands/run#config)), and users don't technically need to use a root `terragrunt.hcl` file or to name it that. This is the most common pattern followed by the community, however, and deviation from this pattern should be justified in the context of the project. It can help others with Terragrunt experience understand the project more easily if industry standard patterns are followed.
52
52
53
53
### Stack
54
54
@@ -154,17 +154,17 @@ These utilities are part of what makes Terragrunt so powerful, as they allow use
154
154
155
155
The Run Queue is the queue of all units that Terragrunt will do work on over one or more runs.
156
156
157
-
Certain commands like [run-all](/docs/reference/cli-options/#run-all) populate the Run Queue with all units in a stack, while other commands like `plan` or `apply` will only populate the Run Queue with the unit that the command was run in.
157
+
Certain commands like [run-all](/docs/reference/cli/commands/run#all) populate the Run Queue with all units in a stack, while other commands like `plan` or `apply` will only populate the Run Queue with the unit that the command was run in.
158
158
159
-
Certain flags like [--include-dir](/docs/reference/cli-options/#include-dir) can be used to adjust the Run Queue to include additional units. Conversely, there are flags like [--exclude-dir](/docs/reference/cli-options/#exclude-dir) that can be used to adjust the Run Queue to exclude units.
159
+
Certain flags like [--include-dir](/docs/reference/cli/commands/run#include-dir) can be used to adjust the Run Queue to include additional units. Conversely, there are flags like [--exclude-dir](/docs/reference/cli/commands/run#exclude-dir) that can be used to adjust the Run Queue to exclude units.
160
160
161
161
Terragrunt will always attempt to run until the Run Queue is empty.
162
162
163
163
### Runner Pool
164
164
165
165
The Runner Pool is the pool of available resources that Terragrunt can use to execute runs.
166
166
167
-
Units are dequeued from the Runner Pool into the Runner Pool depending on factors like [parallelism](/docs/reference/cli-options/#parallelism) and the DAG.
167
+
Units are dequeued from the Runner Pool into the Runner Pool depending on factors like [parallelism](/docs/reference/cli/commands/run#parallelism) and the DAG.
168
168
169
169
Units are only considered "running" when they are in the Runner Pool.
170
170
@@ -207,15 +207,15 @@ By default, Terragrunt will interact with OpenTofu/Terraform in order to retriev
207
207
208
208
Terragrunt does have the ability to mock outputs, which is useful when dependencies do not yet have outputs to be consumed (e.g. during the run of a unit with a dependency that has not been applied).
209
209
210
-
Terragrunt also has the ability to fetch outputs without interacting with OpenTofu/Terraform via [--fetch-dependency-output-from-state](/docs/reference/cli-options/#fetch-dependency-output-from-state) for dependencies where state is stored in AWS. This is an experimental feature, and more tooling is planned to make this easier to use.
210
+
Terragrunt also has the ability to fetch outputs without interacting with OpenTofu/Terraform via [--fetch-dependency-output-from-state](/docs/reference/cli/commands/run#fetch-dependency-output-from-state) for dependencies where state is stored in AWS. This is an experimental feature, and more tooling is planned to make this easier to use.
211
211
212
212
### Feature
213
213
214
-
A [feature](/docs/reference/cli-options/#feature) is a configuration that can be dynamically controlled in Terragrunt configurations.
214
+
A [feature](/docs/reference/cli/commands/run#feature) is a configuration that can be dynamically controlled in Terragrunt configurations.
215
215
216
216
They operate very similarly to variables, but are designed to be used to dynamically adjust the behavior of Terragrunt configurations, rather than OpenTofu/Terraform configurations.
217
217
218
-
Features can be adjusted using feature flags, which are set in Terragrunt configurations using the [feature block](/docs/reference/hcl/blocks#feature) and the [feature flag](/docs/reference/cli-options#feature) attribute.
218
+
Features can be adjusted using feature flags, which are set in Terragrunt configurations using the [feature block](/docs/reference/hcl/blocks#feature) and the [feature flag](/docs/reference/cli/commands/run#feature) attribute.
219
219
220
220
Like all good feature flags, you are encouraged to use them with good judgement and to avoid using them as a crutch to avoid making decisions about permanent adjustments to your infrastructure.
Copy file name to clipboardexpand all lines: docs-starlight/src/content/docs/02-features/02-stacks.mdx
+7-7
Original file line number
Diff line number
Diff line change
@@ -43,7 +43,7 @@ Right now, there is no special syntax for defining a stack as a single file, but
43
43
Regardless of whether you are using the new syntax or not, the core functionality provided by Stacks are the same.
44
44
The new `terragrunt.stack.hcl` file is merely a shorthand for defining a stack, just like you could by placing units directly in a folder.
45
45
46
-
## The `run-all` command
46
+
## The `run --all` command
47
47
48
48
To solve the problem above, first convert the OpenTofu/Terraform modules into units. This is done simply by adding an empty `terragrunt.hcl` file within each root module folder.
49
49
@@ -95,10 +95,10 @@ terragrunt run-all output
95
95
96
96
Finally, if you make some changes to your project, you could evaluate the impact by using `run-all` command with `plan`:
97
97
98
-
Note: It is important to realize that you could get errors running `run-all plan` if you have dependencies between your
98
+
Note: It is important to realize that you could get errors running `run --all plan` if you have dependencies between your
99
99
projects and some of those dependencies haven’t been applied yet.
100
100
101
-
_Ex: If unit A depends on unit B and unit B hasn’t been applied yet, then run-all plan will show the plan for B, but exit with an error when trying to show the plan for A._
101
+
_Ex: If unit A depends on unit B and unit B hasn’t been applied yet, then `run --all plan` will show the plan for B, but exit with an error when trying to show the plan for A._
102
102
103
103
```bash
104
104
cd root
@@ -109,7 +109,7 @@ terragrunt run-all plan
109
109
110
110
If your units have dependencies between them, for example, you can’t deploy the backend-app until MySQL and redis are deployed. You’ll need to express those dependencies in your Terragrunt configuration as explained in the next section.
111
111
112
-
Additional note: If your units have dependencies between them, and you run a `terragrunt run-all destroy` command, Terragrunt will destroy all the units under the current working directory, _as well as each of the unit dependencies_ (that is, units you depend on via `dependencies` and `dependency` blocks)! If you wish to use exclude dependencies from being destroyed, add the `--ignore-external-dependencies` flag, or use the `--exclude-dir` once for each directory you wish to exclude.
112
+
Additional note: If your units have dependencies between them, and you run a `terragrunt run --all destroy` command, Terragrunt will destroy all the units under the current working directory, _as well as each of the unit dependencies_ (that is, units you depend on via `dependencies` and `dependency` blocks)! If you wish to prevent external dependencies from being destroyed, add the `--queue-exclude-external` flag, or use the `--exclude-dir` once for each directory you wish to exclude.
113
113
114
114
## Cutting down the file count
115
115
@@ -549,10 +549,10 @@ cd root/us-east-1
549
549
terragrunt run-all apply
550
550
```
551
551
552
-
Terragrunt will only include the units in the `us-east-1` stack and its children in the queue of units to run (unless external dependencies are pulled in, as discussed in the [run-all command](#the-run-all-command) section).
552
+
Terragrunt will only include the units in the `us-east-1` stack and its children in the queue of units to run (unless external dependencies are pulled in, as discussed in the [run --all command](#the-run---all-command) section).
553
553
554
554
Generally speaking, this is the primary tool Terragrunt users use to control the blast radius of their changes. For the most part, it is the current working directory that determines the blast radius of a `run-all` command.
555
555
556
-
In addition to using your working directory to control what's included in a [run queue](/docs/getting-started/terminology/#run-queue), you can also use flags like [--include-dir](/docs/reference/cli-options/#include-dir) and [--exclude-dir](/docs/reference/cli-options/#exclude-dir) to explicitly control what's included in a run queue within a stack, or outside of it.
556
+
In addition to using your working directory to control what's included in a [run queue](/docs/getting-started/terminology/#run-queue), you can also use flags like [--include-dir](/docs/reference/cli/commands/run#include-dir) and [--exclude-dir](/docs/reference/cli/commands/run#exclude-dir) to explicitly control what's included in a run queue within a stack, or outside of it.
557
557
558
-
There are more flags that control the behavior of the `run-all` command, which you can find in the [CLI Options](/docs/reference/cli-options) section.
558
+
There are more flags that control the behavior of the `run` command, which you can find in the [`run` docs](/docs/reference/cli/commands/run).
0 commit comments