#terraform-0_12 - May 2019

39 messages

Discuss upgrading to terraform 0.12

Archive: https://archive.sweetops.com/terraform-0_12/

Exequiel Barrirero
Exequiel Barrireroover 7 years ago
Almost there!
Exequiel Barrirero
Exequiel Barrireroover 7 years ago(edited)
💪 🚀
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
wow
Exequiel Barrirero
Exequiel Barrireroover 7 years ago(edited)
Finally! Terraform 0.12 is here to stay! 🚀🙌
Exequiel Barrirero
Exequiel Barrireroover 7 years ago
btai
btaiover 7 years ago
i know they really tried to focus on making the 0.11 -> 0.12 migration easy (even providing a migration tool), but im curious to see how much of a headache (or lack thereof) it will be
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
Has anyone done his yet for a sizable terraform codebase?
btai
btaiover 7 years ago
nope, kinda worried to 😂
btai
btaiover 7 years ago
even now some of the providers i use are pretty fickle (when using them together - azure, kubernetes, helm, etc)
Andrew Jeffree
Andrew Jeffreeover 7 years ago
well my first upgrade to 0.12 went well
Andrew Jeffree
Andrew Jeffreeover 7 years ago
but it was a relatively simple thing
Andrew Jeffree
Andrew Jeffreeover 7 years ago
all our datadog monitors
Andrew Jeffree
Andrew Jeffreeover 7 years ago
for all our customers
Andrew Jeffree
Andrew Jeffreeover 7 years ago
so 20~ modules used about 40 times each, with about 3 or 4 resources per module. The most time consuming part was upgrading the modules, docs and publishing new versions etc.
Nikola Velkovski
Nikola Velkovskiover 7 years ago

- vpc.label in .terraform/modules/vpc.label
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: Attribute name required

  on .terraform/modules/dynamic_subnets/private.tf line 34, in resource "aws_subnet" "private":
  34:     ignore_changes = ["tags.%", "tags.kubernetes", "tags.SubnetType"]

Dot must be followed by attribute name.


Error: Attribute name required

  on .terraform/modules/dynamic_subnets/public.tf line 35, in resource "aws_subnet" "public":
  35:     ignore_changes = ["tags.%", "tags.kubernetes", "tags.SubnetType"]

Dot must be followed by attribute name.

Nikola Velkovski
Nikola Velkovskiover 7 years ago
ah 🙂
Nikola Velkovski
Nikola Velkovskiover 7 years ago
Nikola Velkovski
Nikola Velkovskiover 7 years ago
Is there any roadmap for making the module 0.12 compatible? Let me know if I can be of help somehow.
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
We will inevitably support 0.12, but not until there's more mainstream adoption.
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago(edited)
Most likely it will come from (cloudposse) customer demand.
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
I think we might need to start with a master/0.12 branch and go from there.
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
also, it will mess with versions. We'll probably need to affix +0.12 to the semmver
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
e.g. 0.1.2+0.12
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
and doubt we'll be backporting fixes.
Nikola Velkovski
Nikola Velkovskiover 7 years ago
Allright, thanks for the info.
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
Welcome suggestions from community on how we can straddle the two worlds.
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago(edited)
And if the proposal above make sense.
loren
lorenover 7 years ago
loren
lorenover 7 years ago
looks like they might have just run the upgrade tool on everything?
Gosia
Gosiaover 7 years ago
hey, a little question regarding 0.12, seems the feature of generating resources based on count and value list still keeps resources list in statefile in an indexed structure, is there a workaround? Still can’t remove an element from anywhere but the end of the list without forcing a replace on remaining elements.
antonbabenko
antonbabenkoover 7 years ago
I think it is a good idea to read the whole Terraform docs, because there are few things here and there. Attrs as blocks is one of the most trickiest 🙂
loren
lorenover 7 years ago
yeah, i'm not a fan of that change. makes it impossible for many resources to write modules that work for both tf 0.11 and tf 0.12
joshmyers
joshmyersover 7 years ago
Doesn’t look like that module has too many….hairy parts…..the rest of us have been using hacks on hacks on hacks
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
any handy 0.12 cheatsheets?
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago