mirror of
https://github.com/opentofu/opentofu.git
synced 2025-02-25 18:45:20 -06:00
Fixes #10439
When a CBD resource depends on a non-CBD resource, the non-CBD resource
is auto-promoted to CBD. This was done in
cf3a259
. This PR makes it so that we
also set the config CBD to true. This causes the proper runtime
execution behavior to occur where we depose state and so on.
So in addition to simple graph edge tricks we also treat the non-CBD
resources as CBD resources.
13 lines
206 B
HCL
13 lines
206 B
HCL
resource "aws_instance" "foo" {
|
|
require_new = "yes"
|
|
}
|
|
|
|
resource "aws_instance" "bar" {
|
|
require_new = "yes"
|
|
value = "${aws_instance.foo.id}"
|
|
|
|
lifecycle {
|
|
create_before_destroy = true
|
|
}
|
|
}
|