mirror of
https://github.com/hashicorp/packer.git
synced 2026-09-27 02:04:01 -04:00
* evaluateLocalVariables: modify code for readability and some (not benchmarked) perfs * Make default input variable type the DynamicPseudoType This should be the default, and avoids a panic. This type can represent situations where a type is not yet known. Its meaning is undefined in cty. * do not take Empty types from default value * Update types.variables.go Co-authored-by: Wilken Rivera <[email protected]>
19 lines
205 B
HCL
19 lines
205 B
HCL
|
|
variable "foo" {
|
|
default = []
|
|
}
|
|
|
|
variable "bar" {
|
|
default = {}
|
|
}
|
|
|
|
source "file" "base" {
|
|
}
|
|
|
|
build {
|
|
source "sources.file.base" {
|
|
target = "${var.bar.baz}.txt"
|
|
content = var.foo[0]
|
|
}
|
|
}
|