Updated CLI args, config attributes and blocks
dependencies
[BACKWARD INCOMPATIBLE]dependency
include
Description
- Fixed bug where Terragrunt only took the last
include
block into consideration for the dependency run graph. Now alldependency
blocks defined across allinclude
configurations will be taken into consideration.
Migration guide
As a part of this change, the behavior of how dependencies
blocks are merged together in the shallow
merge strategy has been updated to be a deep merge - now all the paths defined in dependencies
blocks across the included modules are always concatenated together rather than replaced. If you have a configuration that depended on the old behavior, you will need to update your configuration to take advantage of multiple include blocks to selectively include the parent dependencies
block.
E.g., if you had the following configurations:
parent terragrunt.hcl
dependencies {
paths = ["../vpc", "../mysql"]
}
# ... other blocks ...
child terragrunt.hcl
include "root" {
path = find_in_parent_folders()
}
dependencies {
paths = ["../new_vpc"] # intended to replace dependencies block in parent
}
# ... other blocks ...
You will want to update to the following:
parent terragrunt.hcl
# ... other blocks ...
dependencies parent terragrunt.hcl
dependencies {
paths = ["../vpc", "../mysql"]
}
child terragrunt.hcl
include "root" {
path = find_in_parent_folders()
}
dependencies {
paths = ["../new_vpc"] # intended to replace dependencies block in parent
}
# ... other blocks ...
child who wants dependencies
include "root" {
path = find_in_parent_folders()
}
include "dependencies" {
path = find_in_parent_folders("dependencies_parent_terragrunt.hcl")
}
# ... other blocks ...