You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On at least Mac with M1 processor, starting in m5 (and then in m6 and further) the use of the template provider in the templates.tf file causes an init error:
➜ networking git:(v2) ✗ terraform init -backend-config="path=networking/state/globo-primary"
Initializing modules...
Downloading registry.terraform.io/terraform-aws-modules/vpc/aws 2.78.0 for vpc...
- vpc in .terraform/modules/vpc
Initializing the backend...
Successfully configured the backend "consul"! Terraform will automatically
use this backend unless the backend configuration changes.
Initializing provider plugins...
- Finding hashicorp/consul versions matching "~> 2.0"...
- Finding hashicorp/aws versions matching ">= 2.70.0, ~> 3.0"...
- Finding latest version of hashicorp/template...
- Installing hashicorp/aws v3.75.2...
- Installed hashicorp/aws v3.75.2 (signed by HashiCorp)
- Installing hashicorp/consul v2.17.0...
- Installed hashicorp/consul v2.17.0 (signed by HashiCorp)
╷
│ Error: Incompatible provider version
│
│ Provider registry.terraform.io/hashicorp/template v2.2.0 does not have a package available for your
│ current platform, darwin_arm64.
│
│ Provider releases are separate from Terraform CLI releases, so not all providers are available for all
│ platforms. Other versions of this provider may have different platforms supported.
I'm using a Macbook Pro:
➜ Deep-Dive-Terraform git:(v2) ✗ terraform version
Terraform v1.3.6
on darwin_arm64
The docs say to use templatefile, but not sure how to do that in the current module setup. I'm doing a workaround for now by renaming the templates.tf file to xxxtemplates.tfxxx (taking it out of the config, basically) and adding two lines to locals in resources.tf and changing two lines in the vpc module to use the two local vars:
Thanks for letting me know David! When I published this course, the for expression didn't yet exist, so template_file was a possible workaround. If you don't mind, I'll borrow what you did and update the exercise files shortly.
You're welcome, and I was just repurposing something you had used before to get the exercise to work.
I am trying to work out a templatefile approach to these variables, just to keep the idea of the "template" example they were meant to show. But I need to learn how to do that, how to pass the right map in, that sort of thing. I'll update if I can figure that out. Thanks!
On at least Mac with M1 processor, starting in m5 (and then in m6 and further) the use of the template provider in the templates.tf file causes an init error:
I'm using a Macbook Pro:
The docs say to use templatefile, but not sure how to do that in the current module setup. I'm doing a workaround for now by renaming the templates.tf file to xxxtemplates.tfxxx (taking it out of the config, basically) and adding two lines to locals in resources.tf and changing two lines in the vpc module to use the two local vars:
The text was updated successfully, but these errors were encountered: