This website requires JavaScript.
Explore
Help
Sign In
resilien
/
terraform
Watch
2
Star
0
Fork
You've already forked terraform
0
Code
Issues
Pull Requests
Projects
Releases
Wiki
Activity
97316f2dae
terraform
/
test-fixtures
/
basic.tfstate
8 lines
109 B
Plaintext
Raw
Normal View
History
Unescape
Escape
provider/terraform: test fixture
2015-05-07 18:59:11 +02:00
{
provider/terraform: Fix outputs from remote state The work integrated in hashicorp/terraform#6322 silently broke the ability to use remote state correctly. This commit adds a fix for that, making use of the work integrated in hashicorp/terraform#7124. In order to deal with outputs which are complex structures, we use a forked version of the flatmap package - the difference in the version this commit vs the github.com/hashicorp/terraform/flatmap package is that we add in an additional key for map counts which state requires. Because we bypass the normal helper/schema mechanism, this is not set for us. Because of the HIL type checking of maps, values must be of a homogenous type. This is unfortunate, as it means we can no longer refer to outputs as: ${terraform_remote_state.foo.output.outputname} Instead we had to bring them to the top level namespace: ${terraform_remote_state.foo.outputname} This actually does lead to better overall usability - and the BC breakage is made better by the fact that indexing would have broken the original syntax anyway. We also add a real-world test and assert against specific values. Tests which were previously acceptance tests are now run as unit tests, so regression should be identified at a much earlier stage.
2016-06-09 14:45:55 +02:00
"version": 1,
provider/terraform: test fixture
2015-05-07 18:59:11 +02:00
"modules": [{
"path": ["root"],
"outputs": { "foo": "bar" }
}]
}