我只是想terrafomr init
成为 opsgenie 的提供者。
我的 terraform 版本是:
Terraform v0.12.6
Your version of Terraform is out of date! The latest version
is 0.14.10. You can update by downloading from www.terraform.io/downloads.html
我的提供者是:
terraform {
# https://www.terraform.io/docs/configuration/terraform.html#specifying-a-required-terraform-version
required_version = "~> 0.12"
# https://www.terraform.io/docs/configuration/provider-requirements.html
required_providers {
opsgenie = {
source = "opsgenie/opsgenie",
version = "~> 0"
}
}
我得到的错误是:
There are some problems with the configuration, described below.
The Terraform configuration must be valid before initialization so that
Terraform can determine which modules and providers need to be installed.
Error: Invalid version constraint
on provider.tf line 16, in terraform:
16: opsgenie = {
17: source = "opsgenie/opsgenie"
18: version = "0.6.3"
19: }
A string value is required for opsgenie.