alpine-docker / terragrunt

Auto-trigger docker build for terragrunt when new terraform version released
Apache License 2.0
35 stars 24 forks source link

Terragrunt image tagged with 0.11.15 has an incompatible terragrunt version (too fresh) #12

Closed JZfi closed 3 years ago

JZfi commented 3 years ago

It seems that the new terragrunt build system packs an incompatible terragrunt version (0.29.0) with the new terraform 0.11.15. You will get HCL-related errors even if there are only old .tfvars/.tf files in our repo. The new tf 0.11.15 version is needed as the provider signing keys at Hashicorp were changed.

$ docker run -ti --rm alpine/terragrunt:0.11.15 bash
bash-5.1# terragrunt --version
terragrunt version v0.29.0

$ docker run -ti --rm alpine/terragrunt:0.11.14 bash
bash-4.4# terragrunt --version
terragrunt version v0.18.6

The error we encounter with the new terragrunt

terragrunt get --terragrunt-source-update
Error reading file at path terragrunt.hcl: open [..]/terragrunt.hcl: no such file or directory
Unable to determine underlying exit code, so Terragrunt will exit with error code 1

The old terragrunt works for our purposes and we bypass this issue atm. using this Dockerfile

FROM alpine/terragrunt:0.11.14
RUN apk add --update --no-cache curl unzip

RUN curl -o terraform.zip https://releases.hashicorp.com/terraform/0.11.15/terraform_0.11.15_linux_amd64.zip
RUN unzip terraform.zip
RUN cp terraform /usr/local/bin/terraform
ozbillwang commented 3 years ago

Thanks for the report, do we have any tickets from Terragrunt about this issue?

terraform 0.11 is bit old to me and imcompatible for all new versions after 0.12+. Yesterday Terraform 1.0 GA was released.

Should we move on to focus on latest version, more than to spend time on these 3+ years old versions?

i would recommend to use the work around so it doesn't block your project, then think about to upgrade your terrafom project to latest ASAP, better to v1.0 GA release directly

ozbillwang commented 3 years ago

no update, closed