hashicorp / terraform-google-consul

A Terraform Module for how to run Consul on Google Cloud using Terraform and Packer
Apache License 2.0
94 stars 90 forks source link

Remove deprecated map function in preparation for Terraform 0.12 #39

Closed gfenn-newbury closed 5 years ago

gfenn-newbury commented 5 years ago

map will be deprecated as of Terraform v0.12 and will get removed at some point thereafter. merge alone appears to achieve what is needed https://www.terraform.io/docs/configuration/functions/merge.html

This will break backwards compatibility

hashicorp-cla commented 5 years ago

CLA assistant check

Thank you for your submission! We require that all contributors sign our Contributor License Agreement ("CLA") before we can accept the contribution. Read and sign the agreement

Learn more about why HashiCorp requires a CLA and what the CLA includes


Guy Newbury seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you already have a GitHub account, please add the email address used for this commit to your account.

Have you signed the CLA already but the status is still pending? Recheck it.

Etiene commented 5 years ago

Thanks for the PR!

merge does not seem to accomplish things alone... it still says it requires two maps and it looks like the { } syntax for maps requires a =. Im gonna kick off our automated tests on this, but will this really work in the same way? How did you test this?

Etiene commented 5 years ago

Also this change does not work on previous versions of terraform according to the tests... parse error at 1:9: expected expression but found invalid sequence "{"

Is there an alternative syntax that could work in both versions?

Etiene commented 5 years ago

I have addressed these changes in #40, so I'll close this PR! :)