【发布时间】:2019-12-08 13:31:09
【问题描述】:
我正在 aks 中的 pod 内运行一个应用程序,即使用 terraform 配置 aws 服务,如果在配置进行期间该 pod 被删除或停止,则 terraform 状态文件已损坏。
当我尝试使用该状态文件再次配置时,我收到应用错误。一些资源已配置但未在状态文件中更新。我收到以下错误。
Error: Error applying plan:
1 error(s) occurred:
* aws_s3_bucket.examplebucket: 1 error(s) occurred:
* aws_s3_bucket.examplebucket: Error creating S3 bucket: BucketAlreadyOwnedByYou: Your previous request to create the named bucket succeeded and you already own it.
status code: 409
那么如何更新状态文件以便我可以再次使用它?
【问题讨论】:
-
尝试 terraform refresh -h
标签: terraform