-
Notifications
You must be signed in to change notification settings - Fork 33
resource_configuration confusion when updating to TF 0.12 #28
Comments
Hi @mcascone With version 0.12 and the latest provider you need to change your declaration, have you tried the following?
The readme has been updated with these change, let us know if it works after the modification! Thanks! |
As I mentioned, I tried that, and it does fix that specific problem. But right below that in the config, I need to pass the ip_address to the provisioner, and it doesn't exist yet: provisioner "chef" {
# This is for TF to talk to the new node
connection {
host = "${self.resource_configuration.vSphere_Machine_1.ip_address}"
Same thing if i change to using the provisioner "chef" {
# This is for TF to talk to the new node
connection {
host = "${self.resource_configuration.vSphere_Machine_1.name}"
|
Sorry missed that part, here's something that works for me, maybe this could help, in my case a simple echo
|
Thanks @hobovirtual, but this doesn't pass validation for me: output "Machine_Names" {
value = "${vra7_deployment.TF-Deploy.resource_configuration.vSphere_Machine_1.ip_address}"
} I am trying to use the ip (or name) in a chef provisioner, and there doesn't seem to be a way to access it: host = "${self.resource_configuration.vSphere_Machine_1.ip_address}" gives the |
also... I noticed that your output has a space in the name: |
I'm sorry... i've got it... from this very repo: https://github.com/terraform-providers/terraform-provider-vra7/blob/master/example/remote-execute/main.tf: connection {
host = self.resource_configuration["Machine.ip_address"] And this took me QUITE a few variations to land on, but this is how I can access the elements of that block: output "Machine_IPs" {
value = vra7_deployment.TF-Deploy[*].resource_configuration["vSphere_Machine_1.ip_address"]
} |
vRA 7.x version
vRA 7.0.1
Terraform version
Describe the bug
after upgrade to TF v0.12, my
resource_configuration
block fails:This happens for all three parameters in the block.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
resource_configuration should pass validation.
Screenshots
If applicable, add screenshots to help explain your problem.
Logs
Attach logs to help debug the issue
Desktop (please complete the following information):
Additional context
This works fine under TF v0.11. The
v0.12upgrade
helper script updated theresource_configuration
block to add the=
:but then gets the error shown above.
Removing the
=
doesn't work. I tried putting the left-side parameters in quotes, but that causes other problems, i don't think that's the issue.The text was updated successfully, but these errors were encountered: