我正在使用 terraform 版本 0.13.2,提供者http://registry.terraform.io/hashicorp/local v2.1.0 并拥有以下资源:
terraform {
required_providers {
local = {
source = "hashicorp/local"
}
}
required_version = ">= 0.13"
}
resource "local_file" "test_local_file" {
content = "This is a test file"
filename = "test.txt"
}
现在,当我只在另一个目录中获取 terraform.tfstate 文件并尝试在新目录中使用 terraform 1.1.2 销毁此配置时,我在 terraform destroy 上收到以下错误:
│ Error: Missing resource schema from provider
│
│ No resource schema found for local_file.
解决方法是什么?