kubernetes-the-hard-way-terraform icon indicating copy to clipboard operation
kubernetes-the-hard-way-terraform copied to clipboard

Terraform scripts are not compatible with 0.12+ version do you want me to fix and raise a pull request?

Open venkateshchanda opened this issue 4 years ago • 2 comments

Warning: Interpolation-only expressions are deprecated

on compute.tf line 6, in resource "google_compute_instance" "k8s_controller": 6: image = "${var.controller_image}"

Terraform 0.11 and earlier required all non-constant expressions to be provided via interpolation syntax, but this pattern is now deprecated. To silence this warning, remove the "${ sequence from the start and the }" sequence from the end of this expression, leaving just the inner expression.

Template interpolation syntax is still used to construct strings from expressions when the template includes multiple interpolation sequences or a mixture of literal strings and interpolations. This deprecation applies only to templates that consist entirely of a single interpolation sequence.

(and 100 more similar warnings elsewhere)

Warning: Quoted references are deprecated

on networking.tf line 82, in resource "google_compute_route" "k8s_worker0route": 82: depends_on = ["google_compute_instance.k8s_worker"]

In this context, references are expected literally rather than in quotes. Terraform 0.11 and earlier required quotes, but quoted references are now deprecated and will be removed in a future version of Terraform. Remove the quotes surrounding this reference to silence this warning.

(and 2 more similar warnings elsewhere)

Error: Unsupported argument

on compute.tf line 17, in resource "google_compute_instance" "k8s_controller": 17: access_config = {}

An argument named "access_config" is not expected here. Did you mean to define a block of type "access_config"?

Error: Unsupported block type

on compute.tf line 21, in resource "google_compute_instance" "k8s_controller": 21: metadata {

Blocks of type "metadata" are not expected here. Did you mean to define argument "metadata"? If so, use the equals sign to assign it a value.

Error: Unsupported argument

on compute.tf line 313, in resource "google_compute_instance" "k8s_worker": 313: access_config = {}

An argument named "access_config" is not expected here. Did you mean to define a block of type "access_config"?

Error: Unsupported block type

on compute.tf line 317, in resource "google_compute_instance" "k8s_worker": 317: metadata {

Blocks of type "metadata" are not expected here. Did you mean to define argument "metadata"? If so, use the equals sign to assign it a value.

venkateshchanda avatar Jan 06 '20 18:01 venkateshchanda

Hey @venkateshchanda! Thanks so much for making the issue man! Sorry about the delay--I've been starting a new job and it's been hectic so my open source game has been lagging. It'd be awesome if you made a PR! I'd want to make a legacy release/branch for all the < 0.11 versions and maybe start drafting releases (for the 0.12 stuff) once you make the changes.

aidanSoles avatar Apr 01 '20 05:04 aidanSoles

Thanks for being willing to contribute and hopefully you learned a lot!

aidanSoles avatar Apr 01 '20 05:04 aidanSoles