Terraform template_file在destroy上没有属性“ rendered”

时间:2018-11-05 23:59:04

标签: terraform terraform-template-file

在运行terraform destroy时出现错误,我的输出是template_file资源的结果,该资源的内容取决于被销毁的资源。

data "template_file" "ansible_inventory" {
  template = "${ ...interpolated string that uses values from the ec2 resources in the next line (e.g. ip addresses etc)... }"
  depends_on = [ ...list of ec2 resources... ]
}

output "ansible_inventory" {
  value = "${data.template_file.ansible_inventory.rendered}"
}

当我进行销毁时,出现错误:

Resource 'data.template_file.ansible_inventory' does not have attribute 'rendered' for variable 'data.template_file.ansible_inventory.rendered'

是否有解决方法?这似乎与此处报告的问题相同:Resource 'data.template_file.user_data' does not have attribute 'rendered'

0 个答案:

没有答案