【发布时间】:2019-12-18 23:35:16
【问题描述】:
我发现我的 aws 帐户中有一个不是由 terraform 创建的存储桶。
我想确保它在我的 terraform 存储库中进行了说明,但在添加它之前,我运行了 terraform plan 并得到以下响应:
No changes. Infrastructure is up-to-date.
This means that Terraform did not detect any differences between your
configuration and real physical resources that exist. As a result, no
actions need to be performed.
这很奇怪,因为当我运行 aws s3 ls 时,我看到了存储桶:
#not real names from obvious reasons
2019-07-15 13:33:16 bucket-from-terrform
2019-07-15 13:19:26 terraform-state-bucket
2019-07-23 17:47:26 bucket-created-manually
更重要的是,当我添加一个名称与之前忽略的存储桶匹配的资源时,terraform 会尝试添加它(即使它已经存在)
发生了什么? terraform 忽略该存储桶的原因可能是什么?
【问题讨论】: