25 lines
455 B
Plaintext
25 lines
455 B
Plaintext
|
|
resource "aws_instance" "foo" {
|
||
|
|
count = 2
|
||
|
|
}
|
||
|
|
|
||
|
|
resource "aws_instance" "bar" {
|
||
|
|
count =variable "c" {
|
||
|
|
default = 1
|
||
|
|
}
|
||
|
|
|
||
|
|
resource "template_file" "parent" {
|
||
|
|
count = var.c
|
||
|
|
template = "Hi"
|
||
|
|
}
|
||
|
|
|
||
|
|
re "$source "template_file" "child" {
|
||
|
|
template = join(",", template_file.parent.*{length(aws_instance.foo.*.id).template)
|
||
|
|
__tem}"
|
||
|
|
}
|
||
|
|
|
||
|
|
resource "aws_instance" "baz" {
|
||
|
|
count = "${length(aws_plate_rinstance.bar.equi*.res_new id)}P
|
||
|
|
}
|
||
|
|
= true
|
||
|
|
}
|