clusterinthecloud / support

If you need help with Cluster in the Cloud, this is the right place
2 stars 0 forks source link

Not compatible with recent version(s) of Terraform #37

Closed willfurnass closed 3 years ago

willfurnass commented 3 years ago
$ git clone https://github.com/clusterinthecloud/terraform.git
$ cd terraform
$ git log | head -1
commit d4cf88e280b676dfd86054b2a868ed0584ac1408
$ terraform --version
Terraform v0.15.3
on linux_amd64

Your version of Terraform is out of date! The latest version
is 0.15.4. You can update by downloading from https://www.terraform.io/downloads.html

$ ssh-keygen -t rsa -f ~/.ssh/aws-key -N ""
$ terraform init aws
Too many command line arguments. Did you mean to use -chdir?

$ terraform init
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.
╷
│ Warning: Version constraints inside provider configuration blocks are deprecated
│ 
│   on provider.tf line 6, in provider "template":
│    6:   version = "2.1"
│ 
│ Terraform 0.13 and earlier allowed provider version constraints inside the provider configuration block, but that is now deprecated and will be removed in a future version of Terraform.
│ To silence this warning, move the provider version constraint into the required_providers block.
│ 
│ (and 5 more similar warnings elsewhere)
╵

╷
│ Error: Invalid reference from destroy provisioner
│ 
│   on compute.tf line 69, in resource "null_resource" "tear_down":
│   69:     private_key = data.local_file.ssh_private_key.content
│ 
│ Destroy-time provisioners and their connection configurations may only reference attributes of the related resource, via 'self', 'count.index', or 'each.key'.
│ 
│ References to other resources during the destroy phase can cause dependency cycles and interact poorly with create_before_destroy.
╵

╷
│ Error: Invalid reference from destroy provisioner
│ 
│   on compute.tf line 70, in resource "null_resource" "tear_down":
│   70:     host        = aws_instance.mgmt.public_ip
│ 
│ Destroy-time provisioners and their connection configurations may only reference attributes of the related resource, via 'self', 'count.index', or 'each.key'.
│ 
│ References to other resources during the destroy phase can cause dependency cycles and interact poorly with create_before_destroy.
willfurnass commented 3 years ago

Ah, just seen the comment here about Terraform > 0.12 not being supported; will close this.